Whatever you meant doesn't apply to both foreach and map.
foreach doesn't work well with changing arrays.
map works well with changing arrays.
foreach can do what the OP wants, but not well.
map doesn't do what the OP wants at all.
In reply to Re^4: Unshift and push inside of map operation.
by ikegami
in thread Unshift and push inside of map operation.
by LNEDAD
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |