in reply to Re: Replace the last letter
in thread Replace the last letter

It seems to me that this was recently posted about on this site.
#!/usr/bin/perl use strict; my $find = "r"; my $replace = "X"; my $input = "superfrink"; my $tmp = reverse $input; $tmp =~ s/$find/$replace/; my $output = reverse $tmp; print "input: $input \n"; print "output: $output \n";

Update: Here is the sample output.
frink@scanbox:~ $ ./397370.pl input: superfrink output: superfXink frink@scanbox:~ $