Wel, too bad they did not implement this with python 3, and actually gave some meaning to the type annotations… I mean
def dprod(l0: list[int], l1: list[int]): return sum(x * y for x, y in zip(l0, l1))
Wouldn't it be much nicer?
def dprod(l0: list[int], l1: list[int]): return sum(x * y for x, y in zip(l0, l1))
Wouldn't it be much nicer?
To the number crunchers, Python 3.* offers no compelling reason to move (except for threats, "you are on your own now, 2.7.* will not get updates"). I see two compelling advantages that 3.* offers (i) better abstractions for asynchrony (ii) UTF strings (that exacts a cost even if you don't need them). If you don't need these two there I see no technical reason to move (political/social reasons yes, technical not really).
edit: typo