I am attempting to write some programming and I seem to be having some difficulties. I want to make a certain range into a list, and then take user's input and check if it is in the range. Here is what I have so far:
lower = 1
upper = 10
range_list = list(range(lower, upper +1))
user_input = input()
while user_input in range_list:
print('foo')
else:
print('fee')
Currently, if I input a number that theoretically should be in the range (say, 5), it prints 'fee' rather than 'foo'. What am I doing wrong?