No such thing as a small change | |
PerlMonks |
Re^2: One liner to subtract by 2by derby (Abbot) |
on Jul 24, 2013 at 14:08 UTC ( [id://1046123]=note: print w/replies, xml ) | Need Help?? |
You'll lose leading zeros with that.
-derby
update: so perl -pe 's/([0-9]{10})$/sprintf("%010d", $1-2)/e'
In Section
Seekers of Perl Wisdom
|
|