Add solution method for project_euler/problem_37 (#2998)

* add solution method

* fix formatting
This commit is contained in:
Wen Hong 2020-10-07 20:57:14 -07:00 committed by GitHub
parent f3fe29cea1
commit 6541236fdf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -87,5 +87,12 @@ def compute_truncated_primes(count: int = 11) -> list[int]:
return list_truncated_primes
def solution() -> int:
"""
Returns the sum of truncated primes
"""
return sum(compute_truncated_primes(11))
if __name__ == "__main__":
print(f"{sum(compute_truncated_primes(11)) = }")