cords = []
for y in range(10):
for x in range(10):
cords.append((x, y))
print cords
print cords[11]
user_x=raw_input("X: ")
user_y=raw_input("Y: ")
xy = "("+user_x+", "+user_y+")"
print xy
if xy in cords:
print "Found Match"
My question is, why doesn’t it print “Found Match”, when given 1 and 1 or any other match?
Because a string will never be equal to a tuple.