from person import Person, Manager bob = Person('Bob Smith') sue = Person('Sue Jones', job='dev', pay=50000) tom = Manager('Tom Jones', 'mgr', 60000) import shelve db = shelve.open('t2db') db['bob'] = bob db['sue'] = sue db['tom'] = tom db.close()