Python Collections; Lists, Tuples, Dictionaries and Sets.

I am an IT student with a strong passion and proficiency in programming. I have solid experience working with.
Collectios refers to container data types used for storing and organizing multiple items.Collections make your programs more efficient and easier to manage. In this article, we willl explore Lists, Tuples, Dictionaries, and Sets.lets get started.
- Lists: Ordered, mutable sequences that can store large data. Declared with square brackets
[].Items stored in the list can be of different data types.
How lists are declared and some few methods used on list.

- Tuples: Ordered, immutable sequences, also capable of storing heterogeneous data. Declared with parentheses
().
How to work with tuples in python, remember tuples are immutable meaning unchanged unce declared.

A set is an unordered collection of unique elements in python.
No duplicate items allowed.
Declared with curly braces
{}Elements can be of different data types.
How to work with sets in python and some methods used.

A dictionary in Python is a collection of key-value pairs in python.
Keys are unique and immutable (strings, numbers, tuples).
Values can be of any data type.
How to work with dict in python and some methods used.

comparison table for Python collections

Note: Mutable means changeable and Immutable mean unchangeable.
by Musumba BIT 3.



