As poj suggests, using reverse allows you to use the positions without any messy arithmetic. Here is an example from another thread. A similar approach can be useful when splice'ing several elements into different positions in an array.
Cheers,
JohnGG
In reply to Re: How to use Substr to bulk substitutions?
by johngg
in thread How to use Substr to bulk substitutions?
by phoenix007
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |