http://www.perlmonks.org?node_id=270075


in reply to split questions

Everyone above responded "use an array", and that's good advice.

I'd like to go one step further and say that any time you have sequentially numbered variables (like $_r1, $_r2), think about using an array. Using an array will make the code more readable and more maintainable.

HTH...