© 2026 LinearBytes Inc.
Search posts, tags, users, and pages
Dhruv Jain
>>>cast= ("1","2") >>> cast.append("Gilliam") Traceback (most recent call last): File "<pyshell#44>", line 1, in <module> cast.append("Gilliam") AttributeError: 'tuple' object has no attribute 'append'
Luis Orduz
Software Engineer
Tuples are immutable. Once you declare it, you cannot change it, which is why they don't have methods like append.
You probably want a list, that is declared with braces [].
[]
I got it
Thanks a lot! :)
Luis Orduz
Software Engineer
Tuples are immutable. Once you declare it, you cannot change it, which is why they don't have methods like append.
You probably want a list, that is declared with braces
[].