I am working in Julia 1.4. I would like to open two large gzipped files (file1.gz and file2.gz) and then read the first line from file 1, the first line from file 2, do something with these, and then move on to the second line of each file etc. If I nest two for loops, this obviously does not work because it cycles through file2 before moving on to the next line of file1. The files are two big to open all at once.
handle1 = GZip.open(file1.gz)
handle2 = GZip.open(file2.gz)
for line1 in eachline(handle1)
for line2 in eachline(handle2)
println(line1,line2)
end
end
Is there a simple solution ?