+ 1

Which are immutable in python?

tuple, strings

19th Mar 2018, 4:02 PM
Nachiappan
2 Antworten
+ 6
tuples are immutable
19th Mar 2018, 5:58 PM
Shivadharshini Nagaraju
Shivadharshini Nagaraju - avatar
+ 5
a mutable object can be changed after it is created, and an immutable object can't. Objects of built-in types like (int, float, bool, str, tuple, unicode) are immutable. Objects of built-in types like (list, set, dict) are mutable. Custom classes are generally mutable
19th Mar 2018, 4:07 PM
Baraa AB
Baraa AB - avatar