The '$' means the end of the string./(.{2})$/
perl -le 'my $str="qwerty"; $str=~m/(.{2})$/; print $1;' #output ty
In reply to Re: Printing last two characters
by olus
in thread SOLVED Printing last two characters
by Slug
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |