The user is supposed to enter a number from 1 to 10 and the code is supposed to check for 3 conditions if the input is not a number ask for entering again, if the input is out of 1-10 ask for entering again, and if the number is in range of 1-10 break the loop and store the value in the variable. the first two checks are running correctly, but the last is not working, the loop does not break, and it says invalid input like other conditions. What is the problem?
while True:
num_guess = input("How many times you want to guess [1-10]: ") # Asking for number of guess
if num_guess != int: # Checking for non number input
print("Invalid input")
elif int(num_guess) < 1 or int(num_guess) > 10: # Checking for out of range input
print("Invalid input")
elif 1 <= int(num_guess) <= 10: # if input is in the range just break the loop and store the answer
break