No such thing as a small change | |
PerlMonks |
Re: Removing dotsby Dietz (Curate) |
on May 08, 2005 at 14:11 UTC ( [id://455004]=note: print w/replies, xml ) | Need Help?? |
This would remove all dots except the rightmost one: s/\.(?=.*\.)//g; A single dot occuring only once in the string will not be removed.
In Section
Seekers of Perl Wisdom
|
|