in reply to How to cut strings from the end
You want substr.
Or if you want to remove the last three characters, too,my $string = 'perl345'; my $tag = substr $string, -3;
my $string = 'monks 1223'; my $tag = substr $string, -3, 3, '';
After Compline,
Zaxo
|
|---|