Run
tuple1 = (5, 3, 2, 8, 4, 4, 6, 2) #check if element is present if 8 in tuple1: print('8 is in the tuple', tuple1) else: print('8 is not in the tuple', tuple1) if 9 in tuple1: print('9 is in the tuple', tuple1) else: print('9 is not in the tuple', tuple1)
Output