I have a list, in which is another list and I want to doc.write(a)
doc.write(a)
a = [[1, 2, \"hello\"], [3, 5, \"hi There\"], [5,7,\"I don\'t know\"]]
You can try something like
>>> a = [[1, 2, "hello"],[3, 5, "hi There"],[5,7,"I don't know"]] >>> >>> ''.join(str(r) for v in a for r in v) "12hello35hi There57I don't know"
i.e.
doc.write(''.join(str(r) for v in a for r in v))