Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import shelve
- from contextlib import closing
- with closing(shelve.open('test_shelf.db')) as s:
- s['key1'] = {'int': 10, 'float': 9.5, 'string': 'Sample data'}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement