|
Hello,
A heavy way with regular expression :
$n =~ s/^(.{5})./$1\^/;
Here I suppose for example you want to change the 6th character in string - The reason for the 5 : 6 -1 between {}. The first "^" means the the beginning of the string and the second with the backslash before means the character "^" and not the beginning of the string like the first one.
|