Comment

Anonymous

Actually, the two are not quite the same. readlines() will return newlines on the end of your strings, while readline() will not.

Replies

Ludvig Ericson

>>> f.readline()
'\x1b[0;35m .vir. d$b\n'
>>> f.readlines()
['\x1b[0;35m .d$$$$$$b. .cd$$b. .d$$b. d$$$$$$$$$$$b .d$$b. .d$$b.\n', (cut) ]

Notice how both end in \n.