Python/Maths/gcd.py

13 lines
151 B
Python
Raw Normal View History

2018-10-02 08:57:19 +00:00
def gcd(a, b):
if a == 0 :
return b
return gcd(b%a, a)
def main():
print(gcd(3, 6))
if __name__ == '__main__':
main()