http://qs321.pair.com?node_id=11100118


in reply to How to use Substr to bulk substitutions?

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