GMgKe586q6suSQnyqZLlGCooeWM

Pages

Search

Monday, March 21, 2011

Python - Data Compression With zlib

The first step is import it
>>> import zlib
Then do compress your data
>>> data = 'What this would like to be compressed if you do what you hope'
>>> comprez = zlib.compress(data)

If you want to decompress it, use
>>> decomprez = zlib.decompress(comprez)
Share/Bookmark

No comments:

Post a Comment