📅  最后修改于: 2022-03-11 14:46:14.182000             🧑  作者: Mango
# strings are immutable in Python,
# we have to create a new string which
# includes the value at the desired index
s = s[:index] + newstring + s[index + 1:]