Python Data Structures | Python Journey

 

What is a List?

In Python data structure, a list refers to a collection of items that are ordered and malleable, i.e., they can be changed.

Lists are heterogeneous in nature, as they can contain elements of different data types such as integer, string, or even another list.

What is a Tuple?

Tuple refers to a structured set of elements that are nevertheless immutable and thus cannot be modified post-creation.

Post a Comment

0 Comments