Created
January 15, 2019 11:33
-
-
Save mewforest/70d282887881f63e1a704ecb5bd711b0 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pickle | |
# write pickle | |
file_write = open('pin.dat', 'wb') | |
a = list(range(1000)) | |
pickle.dump(a, file_write) | |
file_write.close() | |
# read pickle | |
file_read = open('pin.dat', 'rb') | |
v = pickle.load(file_read) | |
file_read.close() | |
print(v) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment