Skip to content

Commit e75c072

Browse files
authored
To perform mutation of string
1 parent 53161ee commit e75c072

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Mutations.py

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
def mutate_string(string, position, character):
2+
string = string[:position] + character + string[position+1:]
3+
return string

0 commit comments

Comments
 (0)