The JavaFan code works for sure, but it looks like c/c++ way:
incrementing a number, you've got the index reference...
but it doesn't appear too pearlish.
There is a way to do it in a more perlish way?
AnomalousMonk, I don't understand perfectly your code.
You see, I'm only a novice.
Please, Can you do a better explains?