Python Dicts
A dict is a value in Python that stores multiple values. In that sense, a dict it is quite similar to a list. The main difference is that each value in a list gets an index (0, 1, 2, ...), but in a dict each value gets a key instead, such as name, age, etc. Let's take a closer look at dicts works in this lecture.
Lecture material
Recommended reading
- The following chapters in the book How to Think Like a Computer Scientist: Interactive Edition: