in reply to Re^2: Progressive matching w/substitutions
in thread Progressive matching w/substitutions
Neither of those produces the desired output for me. $x is never incremented. Since you require a space at the end of the string-to-be-substituted, there is no substitution after the last abc, and the desired spacing in the output is wrong:
Those problems were present in the OP's posted code. They weren't problems with the post to which you replied. Presumably, the OP's code is different than what he posted, since the output he gave doesn't match the code he posted. Since the OP will have to retrofit the solution anyway, these details aren't important. That's why I took a few small liberties in my own solution.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Progressive matching w/substitutions
by broomduster (Priest) on Aug 09, 2008 at 10:50 UTC | |
by argv (Pilgrim) on Aug 09, 2008 at 16:47 UTC |