fix indentation that caused logic bug
This commit is contained in:
parent
290d3d994a
commit
1af6fb5298
|
@ -138,9 +138,9 @@ following loop, which searches for prime numbers::
|
|||
... if n % x == 0:
|
||||
... print n, 'equals', x, '*', n/x
|
||||
... break
|
||||
... else:
|
||||
... # loop fell through without finding a factor
|
||||
... print n, 'is a prime number'
|
||||
... else:
|
||||
... # loop fell through without finding a factor
|
||||
... print n, 'is a prime number'
|
||||
...
|
||||
2 is a prime number
|
||||
3 is a prime number
|
||||
|
|
Loading…
Reference in New Issue