Programming Code Center(PCC)
[PYTHON]

(PCC)::[How-to-write-Python-Program-to-Convert-Decimal-to-Binary-Using-Recursion]::[python]

File Name : Convert_Decimal_to_Binary_Using_Recursion.py

# Function to print binary number using recursion
def convertToBinary(n):
   if n > 1:
       convertToBinary(n//2)
   print(n % 2,end = '')

# decimal number
dec = 34

convertToBinary(dec)
print()

Output :

Convert_Decimal_to_Binary_Using_Recursion.jpg