May-02-2019, 03:43 AM
If memory is not the issue, then simple brute force: 'give me last line from list of lines, split it and give length' can deliver result:
>>> with open('last_row.txt', 'r') as lines: ... print(len(lines.readlines()[-1].split())) ... 4
I'm not 'in'-sane. Indeed, I am so far 'out' of sane that you appear a tiny blip on the distant coast of sanity. Bucky Katt, Get Fuzzy
Da Bishop: There's a dead bishop on the landing. I don't know who keeps bringing them in here. ....but society is to blame.
Da Bishop: There's a dead bishop on the landing. I don't know who keeps bringing them in here. ....but society is to blame.