Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/ActiveState/code
/ gcd
Function
gcd
recipes/Python/578421_Greatest_CommDivisor_using/recipe-578421.py:1–8 ·
view source on GitHub ↗
(a,b)
Source
from the content-addressed store, hash-verified
1
def
gcd(a,b):
2
t = b
3
b = a % b
4
5
if
b == 0:
6
return
t
7
else
:
8
return
gcd(t,b)
9
10
def
main(argv):
11
if
(len(sys.argv) != 3):
Callers
2
main
Function · 0.70
keygen
Function · 0.50
Calls
no outgoing calls
Tested by
no test coverage detected