Possible Duplicate:
python: how to jump to a particular line in a huge text file?
I'm trying to read various lines out of a large (250Mb) file.
The header tells me where certain parts are, i.e. the history subsection of the file starts at byte 241817341.
So is there a way to read the file only starting at that byte, without having to go through the rest of the file first? Something like:
file = open(file_name,'r')
history_line = file.readline(241817341)
while history_line != 'End':
history_line = file.readline()
[Do something with that line]
Is that sort of thing feasible?