In 5.10.0 and 5.10.1, $#a adds magic, so there's a performance penalty to $#a too. Either way, the cost has got to be minor.
Note that $#a only adds magic when $#a is used in an lvalue context in 5.12.
In reply to Re^4: How can I delete an element in a foreach cycle?
by ikegami
in thread How can I delete an element in a foreach cycle?
by saintex
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |