In this python tuple program, we will convert a binary tuple to an integer.
Steps to solve the program
tup = (1,0,0)
print("Original tuple is : ",tup)
result = int("".join(str(val) for val in tup), 2)
print("Decimal number: ",result)
Output :
Original tuple is : (1, 0, 0)
Decimal number: 4