2 ms·
Right, I should have said clever code golf. I think I would have written it like that: def parse(line): p = line.split(",") return ((int(p[0],
by bombela 3y ago
Right, I should have said clever code golf.
I think I would have written it like that:
def parse(line):
p = line.split(",")
return ((int(p[0], 16), int(p[2], 16))
(parse(line)) for line in fp)
And when it was still cool: map(parse, fp)