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

hotshot has asked for the wisdom of the Perl Monks concerning the following question:

Hi guys !

Is there a short way to get the x entry of an array returned from a function?

example:
# if I have the function myFunc() that returns an list # I would like to get somehow the 5 element of the list returned: $elem = myFunc()[5]; # of course that doesn't work
anyone?

Hotshot