1 | initial version |
I'm not sure if this is what you're trying to do:
sage: a = [2/3, 3/4, 5/6]
sage: for x in a:
....: with open('results', 'wb') as F:
....: F.write(dumps(a))
....:
sage: with open('results', 'rb') as F:
....: B = loads(F.read())
....:
sage: B
[2/3, 3/4, 5/6]