Mok-Kong Shen wrote:
> A newbie's question of curiosity:
>
> If I have
>
> g=[1,[2]] and
>
> bg=bytearray(str(g),"latin-1")
>
> could I somehow get back from bg a list g1 that is the same as g?
Not for arbitrary values, but for lists, ints, and a few other types that's
not a problem:
>>> g
A newbie's question of curiosity:
If I have
g=[1,[2]] and
bg=bytearray(str(g),"latin-1")
could I somehow get back from bg a list g1 that is the same as g?
Thanks in advance.
M. K. Shen
--
https://mail.python.org/mailman/listinfo/python-list