Initial commit: Python learning project with examples and exercises
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
#4.2.1
|
||||
a = int(input())
|
||||
b = int(input())
|
||||
|
||||
if a>b:
|
||||
a,b=b,a
|
||||
for i in range(a,0,-1):
|
||||
if a%i==0 and b%i==0:
|
||||
print(i)
|
||||
|
||||
while b!=0:
|
||||
a,b=b,a%b
|
||||
print(a)
|
||||
Reference in New Issue
Block a user