in reply to Re: Understanding a portion of perlretut
in thread Understanding a portion on the Perlretut
I thought the documentation said that:
... which printsGot a TGA stop codon at position 18 Got a TGA stop codon at position 23Position 18 is good, but position 23 is bogus. What happened?
The answer is that our regexp works well until we get past the last real match. Then the regexp will fail to match a synchronized TGA and start stepping ahead one character position at a time, not what we want. The solution is to use \G to anchor the match to the codon alignment: ...
If there is no match at all, I would assume that we are always past the last real match.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Understanding a portion of perlretut
by BlueStarry (Novice) on Dec 09, 2015 at 15:52 UTC | |
by Corion (Patriarch) on Dec 09, 2015 at 15:55 UTC | |
by BlueStarry (Novice) on Dec 09, 2015 at 16:15 UTC | |
by AnomalousMonk (Archbishop) on Dec 09, 2015 at 22:04 UTC | |
by Athanasius (Archbishop) on Dec 10, 2015 at 09:54 UTC | |
| |
by Anonymous Monk on Dec 09, 2015 at 22:39 UTC | |
by Discipulus (Canon) on Dec 10, 2015 at 11:12 UTC |