+ 1
Can we change value of list of tuple?
Example list = [1,2,(3),4,5] I want to change value of 3 is it possible?
3 Réponses
+ 6
Hi you can just overwrite it with new tuple so you need to edit list[2] =(4) but you can not edit tuple inside as it is immutable.
+ 4
list[2] is no tuple, btw.
You have to write (3,).
+ 1
okay, Thanks