We don't bite newbies here... much | |
PerlMonks |
Re^3: how to count the number of repeats in a string (really!)by oha (Friar) |
on Nov 16, 2007 at 14:58 UTC ( [id://651227]=note: print w/replies, xml ) | Need Help?? |
i added a line marked with # fix
as i explained, there is a bug in the code you used to rearrange: you must add the fix pos($s)=pos($s)+1-length $1; at the end of the while:;
i apologize for the bug Oha
In Section
Seekers of Perl Wisdom
|
|