4 Réponses
+ 11
I just looked this up.
apparently strings are immutable in python.
you have to make a new string.
old = "longtie"
print(old)
new = old.replace("e", "em")
print(new)
https://stackoverflow.com/questions/3559559/how-to-delete-a-character-from-a-string-using-python
+ 2
LONGTIE Checck out my last question please
+ 1
LONGTIE correct
0
old="longtime"
print(old)
new=del(old)
old="longtime"
print(old)
old.remove(old)