$a = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"; # (remember perl strings start at position 0) substr($a,9,11) = "0123456789-"; print "\$a='$a'\n";