I saved a list
to a csv
and want to import it again but it's in string
format now. Is there a simple way to convert it to a list
again?
string = '[(1, 2), (3, 4), (5, 6)]'
L = list(map(int, string))
print(L)
Error:
L = list(map(int, string))
ValueError: invalid literal for int() with base 10: '['