Write a program to add 2 binary numbers


Topic: Write a program to add 2 binary numbers

Solution

num1 = '00001'
num2 = '10001'
sum = bin(int(num1,2) + int(num2,2))
print(sum)



List all Python Programs