Or using substr to insert a string between two characters:
$_ = 0; substr $str, $_ + 1, 0, '/' while ($_ = index $str, 'CO', $_) > -1;
In reply to Re^2: How to insert a "/" within a string?
by GrandFather
in thread How to insert a "/" within a string?
by rsvp1920
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |