in reply to Re: finding substrings that have been inserted into a string
in thread finding substrings that have been inserted into a string
Well, is it a flaw that you don't report the final "---" at the end of the "new_string"? Your while loop is based on the length of the "old_string", and when that's done, you're not checking whether there's anything left in the new_string beyond the last match. It would be an easy thing to add an element to %gaps after the while loop, if the current value of $n_new is less than $#new_array.
|
|---|