how do I check the format of user input during a loop?
"Write a program that prompts a user to enter a positive whole number less than 2000.Your program should contain an input validation loop that checks the range and the format of the user's input.If the input is valid, your program should display the hexadecimal representation of the number. If the input is out of range, your program should display the message: "Invalid range. Try again." If the input is the wrong format, your program should display the message: "Invalid number. Try again." The program should loop until the user enters a valid number."
you can just do like this..
if (your requirement here)