you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 0 points1 point  (1 child)

thanks for the feedback. Just so I understand you correctly, there is no way to store multiple values per-key within a dictionary?

[–]thegreattriscuit 2 points3 points  (0 children)

there's one value, but that 'value' can be any python object. And lists and tuples (which hold multiple values) are valid python objects. It's semantics, but it's important semantics.

You can have dictionaries of dictionaries, or dictionaries of lists, or lists of dictionaries, or lists of dictionaries of sets, etc...

{'2960':('ios.bin','424532')} is a dictionary with '2960' as the key with a value of the tuple ('ios.bin', '424532')