I’m not going to use a fancy list of Avengers to make my point. I’m still reeling from the ending. Plus, most of the Avengers that they killed off were people of color. My only thought, as I shake my head, is apparently Thanos is racist too. Damn it! The next section of my data type series is dealing with dictionaries in Python.
Dictionaries are useful in a myriad of situations. It’s similar in function to a miniature database, creating small relational models between your values during run time. Most multi-language devs will know them as associative arrays. Instead of using a number to index our values we use keys. These keys can be any immutable object type, strings, numbers or tuples. Key value pairs are an easy way to think about dictionaries. We can do a lot with dictionaries. Where we have to sort through a list, a value can be accessed directly using its key.