I have a list variable with initial value '_____'. I want to replace all '_' with some numbers, but I am getting the following error: TypeError: 'str' object does not support item assignment.
Here is my code.
>>> t
'____'
>>> t[1]=2
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: 'str' object does not support item assignment