I'm surprised that nobody has mentioned that substr returns an lvalue. In other words, you can assign to it.
my $string = 'mystring123456'; substr($string, 8, 1) = ''; print "$string\n";
In reply to Re: How do I cut single characters out of a string
by tobyink
in thread How do I cut single characters out of a string
by akechnie
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |