import pickle
f = open('users.txt', 'rb')
e = pickle.load(f)
import pickle
f = open('users.txt', 'rb')
e = pickle.load(f)
while e.keys() != '':
print(pickle.load(f))
from pickle import dumps, load
def store(arg):
f = open('file.txt', 'w')
f.write(dumps(arg))
f.close()
def extract():
f = open('file.txt', 'r')
result = load(f)
f.close()
return result
d0 = {'one': 1, 'two': 2}
store(d0)
d1 = extract()
print d1