in reply to shift doesn't DWIM
There are enough times when one just wants to get rid of the first element in an array, via:
It would be a nuisance to have to create a spitoon-like variable just to catch the shift'ed element (thereby preserving $_). And it would be easy to forget to do this, leading to many chomped butts.shift @array;
the lowliest monk
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: shift doesn't DWIM
by japhy (Canon) on Jul 12, 2005 at 12:27 UTC | |
by GrandFather (Saint) on Jul 12, 2005 at 20:25 UTC | |
|
Re^2: shift doesn't DWIM
by Fletch (Bishop) on Jul 12, 2005 at 12:22 UTC |