From perldata:
If you evaluate an array in scalar context, it returns the length
of the array. (Note that this is not true of lists, which return the last
value, like the C comma operator, nor of built-in functions, which
return whatever they feel like returning.)
An empty list doesn't have any values, so trying to get the last value gives you undef.
| We're not surrounded, we're in a target-rich environment! |
|---|
In reply to Re^3: Hash problem
by jasonk
in thread Hash problem
by Nesh
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |