2
0
mirror of https://github.com/m-labs/artiq.git synced 2024-12-28 20:53:35 +08:00

examples/coredev_test: use booleans

This commit is contained in:
Sebastien Bourdeauducq 2014-08-18 23:16:02 +08:00
parent 3a6bed43e6
commit f6bbcb6789

View File

@ -17,12 +17,12 @@ class CompilerTest(AutoContext):
m = self.get_max()
while x < m:
d = 2
prime = 1
prime = True
while d*d <= x:
if x % d == 0:
prime = 0
prime = False
d = d + 1
if prime == 1:
if prime:
self.output(x)
x = x + 1
self.led.set(0)