$foo[1] returns you a scalar and @foo[1] returns you a one element list.
If you do it in a context which is sensible to being in scalar or list context, it might bite you, hence the message given by warnings.
CountZero
"If you have four groups working on a compiler, you'll get a 4-pass compiler." - Conway's Law
In reply to Re: @array[1] is valid??
by CountZero
in thread @array[1] is valid??
by jdklueber
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |