Sized DictionaryBy : Oxford english dictionary
This script is a good demonstration of inheriting Python Default object types. It defines a maximum size (items, not bytes) to limit to and use as a normal dictionary (be careful to have KeyError exception handling, ...