Python program to find the GCD of two numbers using recursive

0
595
def gcd(x,y):
    if(y==0):
        return x
    else:
        return gcd(y,x%y)
x=int(input("Please enter first number: "))
y=int(input("Please enter second number:"))
GCD=gcd(x,y)
print("GCD of two numbers is: ", GCD)

     Output 1:
             Please enter first number: 27
             Please enter second number:18
             GCD of two numbers is:  9
     Output 2:
             Please enter first number: 28
             Please enter second number:16
             GCD of two numbers is:  4

इन्हें भी देखें।

Python Programs के लिये यहाँ click करें।

 

 

 

 

Python program to find the GCD of two numbers using recursive program to find the GCD of two numbers using recursive in python write a python program to find the GCD of two numbers using recursive write a program to find the GCD of two numbers using recursive write a program to find the GCD of two numbers using recursive in python program to find the gcd of two numbers in python program to find the gcd of two numbers using recursive in python python program to find the gcd of two numbers using recursion program to find gcd of two numbers using recursion program to find gcd of two numbers using recursion in python write a program to find the gcd of two numbers using recursion write a python program to find the gcd of two numbers using recursion program to find gcd of 2 numbers using recursion in python gcd of two no using recursion how to find gcd of two numbers in python using recursion write a recursive function to find the gcd of two numbers program to find gcd of two numbers in python using recursion python program to find gcd of two numbers using recursion wap to find gcd of two numbers using recursion

LEAVE A REPLY

Please enter your comment!
Please enter your name here