I have the following code snippet and I get the memory error on the last line rows = list(reader)
for file in fileList:
fileName, fileExtension = os.path.splitext(file)
if fileExtension == ".csv":
with open(path + '\\' + file, "rU") as f:
reader = csv.reader(f, delimiter=',', dialect="excel")
rows = list(reader)
Is there any other approach I can use?
readerand it will lazily produce each line.