what is the difference between list and tuples in Python? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 7

what is the difference between list and tuples in Python?

Pyton

3rd Jul 2020, 4:22 PM
Samuel Ekawu
Samuel Ekawu - avatar
6 Answers
+ 6
Lists are mutable objects which means you can modify a list object after it has been created. Tuples, on the other hand, are immutable objects which means you can't modify a tuple object after it's been created.
3rd Jul 2020, 4:24 PM
Arsenic
Arsenic - avatar
+ 2
You can modify a list unlike a tuples. You can't modify tuples. That's all.
3rd Jul 2020, 4:34 PM
Mark W.L.
Mark W.L. - avatar
+ 2
Lists are Mutable whereas Tuples are Immutable
3rd Jul 2020, 5:48 PM
ABHISHEK DHIRANIYA
ABHISHEK DHIRANIYA - avatar
+ 1
Tuples can't be changed
3rd Jul 2020, 4:24 PM
Andrei I
Andrei I - avatar
0
lists can be changed and tuples cant
4th Jul 2020, 5:52 AM
Pr0C0d3r
Pr0C0d3r - avatar