in reply to Re: Shortest -return index of element in array- sub
in thread Shortest -return index of element in array- sub
Saves One char...sub indexArray(@) { 1 while $_[0] ne pop; $#_; }
Could be applied to some of the other solutions (jmcnamara) too...
"Trying to be a SMART lamer" (thanx to Merlyn ;-)
|
---|
In Section
Cool Uses for Perl