Skip to content

Commit 77873f3

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 22d6f5c commit 77873f3

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

maths/sieve_of_eratosthenes.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ def prime_sieve(num: int) -> list[int]:
4646

4747
# marked all even numbers as non-prime
4848
for i in range(3, int(math.sqrt(num)) + 1, 2):
49-
if sieve[i]:
49+
if sieve[i]:
5050
for j in range(i * i, num + 1, 2 * i):
5151
sieve[j] = False
5252

@@ -59,4 +59,4 @@ def prime_sieve(num: int) -> list[int]:
5959

6060

6161
if __name__ == "__main__":
62-
print(prime_sieve(int(input("Enter a positive integer: ").strip())))
62+
print(prime_sieve(int(input("Enter a positive integer: ").strip())))

0 commit comments

Comments
 (0)