Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/geekcomputers/Python
/ find_prime
Function
find_prime
find_prime.py:31–37 ·
view source on GitHub ↗
(num)
Source
from the content-addressed store, hash-verified
29
30
31
def
find_prime(num):
32
res_list = []
33
for
i in range(2, num + 1):
34
if
res_list != [] and any(i % l == 0
for
l in res_list):
35
continue
36
res_list.append(i)
37
return
res_list
38
39
40
if
__name__ ==
"__main__"
:
Callers
1
find_prime.py
File · 0.85
Calls
1
append
Method · 0.45
Tested by
no test coverage detected