1 min readJan 1, 2020
Also incorrect! The key can be any hashable Python data type.
For Python built-in datatypes, the hashable types happen to be the same as the immutable types — but if you create your own class, it is by default hashable even if it’s mutable.