I want to read a huge file in my code. Is read() or readline() faster for this. How about the loop:
for line in fileHandle
If your file is a text file then use readlines() which is obviously the way to read file containing lines. Apart from that: perform benchmarks if you are really aware of possible performance problems. I doubt that you will encounter any issues....the speed of the filesystem should be the limiting factor.