in reply to Check last character of a string

I take it you mean 'string' not 'sting' and you didn't declare the regular expression you tried so I am left wondering if you tried one at all.

I'd probably try something like =~ /\\$/ which is a very simple (but untested) regexp

Try reading perlrequick or perlre

Update: corrected reference and use of incorrect character