zjfz-2019-s439462/intro/Task105.py

9 lines
221 B
Python
Raw Normal View History

2020-01-12 14:35:16 +01:00
def is_almost_prime(number: int, limit: int) -> bool:
if number < 0:
return False
else:
for i in range(2, limit+1):
if number % i == 0:
return False
return True