What is the difference between a list and a tuple in Python?
Easy
5
Added 2025-03-02T10:00:00Z
A list is mutable, meaning you can change its contents after it is created. A tuple is immutable, meaning once it is created, its contents cannot be changed. Lists are defined using square brackets [], while tuples are defined using parentheses ().