...treat @_ as a hash.
You are not TREATING the array as a hash, but in fact COPYING its contents into one. As noted elsewhere by Screamer, using a hash ignores the potential data loss of duplicate keys in the data. splice() is the way to go.
dmm
You can give a man a fish and feed him for a day ...In reply to Re(2): Getting pair of values from an array
by dmmiller2k
in thread Getting pair of values from an array
by vladb
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |