Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #1/usr/bin/env python
- # Pastbin fuck your captchas!
- # this is from The Python
- # Standard Library by example
- # ISBN13: 9780321767349
- try:
- import cPickle as pickle
- except:
- import pickle
- import pprint
- data = [{'a': 'A', 'b': 2, 'c': 3.0}]
- print 'DATA:',
- pprint.pprint(data)
- data_string = pickle.dumps(data)
- print 'PICKLE: %r' % data_string
Add Comment
Please, Sign In to add comment