List vs Set vs Tuple vs Dictionary
Four built-ins cover almost every fresher program. List: ordered, mutable, duplicates OK — [1, 2, 2]. Tuple: ordered, immutable — (1, 2). Set: unordered unique — {1, 2}. Dict: key → value — {"Asha": 90}. Draw a 4-row table in your head: order? can change? duplicates or keys?
That table beats a long speech. Example: unique emails → set. Student record → dict. Marks in exam order → list. RGB colour → tuple. Don’t say “they are all collections” and stop.
List vs Set vs Tuple vs Dictionary — output: list keeps two A, tuple keeps two A, set one A, dict key A→1.
point = (3, 4) immutable
x=3 y=4Four-row table: order, mutable, duplicates/keys.