Mutations

  • + 0 comments

    def mutate_string(string, position, character): string=list(string) string[position]=character string="".join(string) return string

    if name == 'main': s = input() i, c = input().split() s_new = mutate_string(s, int(i), c) print(s_new)