I try to write array to file:
import csv
ofile = open('result.csv', "w")
writer=csv.writer(ofile, delimiter=',',quotechar='|', quoting=csv.QUOTE_MINIMAL)
a=[[1,2],[3,4]]
for i in a:
writer.writerow(i)
ofile.close()
the target file will be:
1,2
3,4
I want to write file without mid empty line here
I want:
1,2
3,4
How should I do it?