Foundation lesson for lists and tuples. Start with the theory and syntax, then connect to a real playlist example.
A list keeps items in order. Index 0 is the first box.
You can change a list later (append, replace, slice).
A list is a single box that stores many values in order. Think of it like a queue or playlist: first item, second item, third item. Python gives each position a number (index), so you can quickly pick or change any item.
Lists are used in shopping carts, marks of students, playlists, chat messages, and any situation where you have many items of the same kind and want to process them one by one.
list[0], last is list[-1].[1, "hi", True] is valid.( ) and is immutable — values cannot change.(lat, lon), RGB (255,0,0).A playlist is a list of songs in order. You access track 1 at index 0, skip to the last at index -1, and slice the "top 3" with playlist[0:3]. Apps also append new songs, remove them, and sort by rating — all list operations.
Answer all questions, then click Check answers. Use this before Practice in the editor.
Q1. What is a list?
Q2. In `nums = [10, 20, 30]`, what is `nums[0]`?
Q3. How do you reverse a list in place?
Q4. Counting evens usually checks…