i have a very large file, which can not be opened by kind of texteditor or something. And i need to Check if (1) the line starts with a specific string and (2) if a number at a specific position (col 148 (3 digits)) is smaller than a predefined number. This complete line should be printed then
so i tried the following code. but it doesnt work.
fobj = open("test2.txt")
for line in fobj:
if (line.startswith("ABS")) and (fp.seek(3, 148) < 400):
print line.rstrip()
Can anyone help me?