Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def replaceIndex( string , index , replacement ) :
- modified_string = string[:index] + replacement + string[index+1:]
- return modified_string
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement