Looking at this string:
rule 1 /^12345678\([0-9][0-9]\)/ /81\1/
I see most of what is going on here, but I am not sure I nuderstand the "\1" in the replaced string.
Is the 1 saying "match what is in the parenthasis in the match string"?
In other words, the first eight digits are getting translated to 81, the last two stay the same as what is in the matched string?
If so, what if "\1" were replaced with "\2"?