list = [1, 2, 3, 4, 5, 6]
number = input("Please enter a number: ")
number = int(number)
while True:
if number != (any element of the list):
number = input("Please enter a number: ")
else:
break
I want the user to enter a number and if that number is not in the list provided the program will ask him to enter that number again until he gets it write