Perl: the Markov chain saw | |
PerlMonks |
Re: remove first and last character of stringby AnomalousMonk (Archbishop) |
on Oct 14, 2020 at 17:17 UTC ( [id://11122837]=note: print w/replies, xml ) | Need Help?? |
As with others who have commented in this thread, it's not clear to me just what flieckster wants to achieve.
If, and it's a big if, the aim is to remove double-quotes
only when they are paired at both the start and end of the
string and never in any other circumstance, then Note that this regex needs Perl version 5.10+ because it uses the (?|...) branch reset regex extension. The regex can be made to work in pre-5.10 versions by removing the (?|...) and adding a grep defined, ... filter to the output of the regex match. Give a man a fish: <%-{-{-{-<
In Section
Seekers of Perl Wisdom
|
|