Lecture 10: Lists and Mutability
This lecture explores list operations and mutability: mutation, aliasing, and tricky examples with loops over L. Lists and tuples provide a way to organize data that naturally supports iterative functions. Tuples are useful when you have data that doesn’t need to change, e.g., (latitude, longitude) or (page #, line #). Lists are useful in dynamic situations, e.g., a list of daily top 40 songs or a list of recently watched movies.
Course Info
Instructor
Departments
As Taught In
Fall
2022
Level
Learning Resource Types
notes
Lecture Notes
theaters
Lecture Videos
podcasts
Podcasts
assignment
Problem Sets
notes
Problem-solving Notes
assignment_turned_in
Programming Assignments with Examples
auto_stories
Readings