http://www.perlmonks.org?node_id=66032


in reply to Re: Shortest -return index of element in array- sub
in thread Shortest -return index of element in array- sub

sub indexArray(@) { 1 while $_[0] ne pop; $#_; }
Saves One char...
Could be applied to some of the other solutions (jmcnamara) too...


"Trying to be a SMART lamer" (thanx to Merlyn ;-)