Skip to content

Commit 3ff43b9

Browse files
Update sol1.py
1 parent 24c99a6 commit 3ff43b9

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

project_euler/problem_095/sol1.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -131,9 +131,8 @@ def solution(max_num: int = 1000000) -> int:
131131
12496
132132
"""
133133

134-
isqrt_max_num = isqrt(max_num)
135-
primes = generate_primes(isqrt_max_num)
136-
chain = [0] * (isqrt_max_num + 1)
134+
primes = generate_primes(isqrt(max_num))
135+
chain = [0] * (max_num + 1)
137136
for prime in primes:
138137
multiply(chain, primes, prime, 1, max_num, 0, {})
139138

0 commit comments

Comments
 (0)