Úgy 0.008s (gondolom kiszámolja előre)
Hogy egy kicsit valósabb helyzetet nézzük: if (i%2 == 0) res += i;
gcc -O3: 0.6s, python3: 53s, pypy3: 2s, numba: 0.3s
Iterator-os formátumban: sum(i for i in range(1, pow(10, 9)) if i%2 == 0):
python3: 54s, pypy3: 17s, numba: The use of yield in a closure is unsupported.