dovysvetleni

2020
Dawid J. Kubis 4 years ago
parent 1e087e00ab
commit 1f1fe67c2e

@ -30,7 +30,7 @@ def generate_primes(lim): # lim je horni hranice intervalu
for i in nums: # prochazime nums a snazime se rasove cistit
# cili nechat jenom cisla ktery nejsou delitelna nove pridanym
# prvocislem
if i % x:
if i % x: # True jenom pokud `i % x` neni 0 -> nedelitelny
temp.append(i) # temp nam slouzi jako budouci nums
nums = temp # pozirame temp a aktualizujeme nums

@ -28,7 +28,7 @@ def generate_primes(lim): # lim je horni hranice intervalu
for i in nums: # prochazime nums a snazime se rasove cistit
# cili nechat jenom cisla ktery nejsou delitelna nove pridanym
# prvocislem
if i % x:
if i % x: # True jenom pokud `i % x` neni 0 -> nedelitelny
temp.append(i) # temp nam slouzi jako budouci nums
nums = temp # pozirame temp a aktualizujeme nums

Loading…
Cancel
Save