I want to find if the first element or the second element matches 3, if so I want to append the tuple to mytuple_with_3.
mytuple=[(1,3),(4,9),(3,8)]
mytuple_with_3 = []
c = 0
for x in mytuple:
if x[0][c] == 3 or x[c][1] == 3:
mytuple_with_3.append(x)
c += 1
result show show (1,3) and (3,8)