How can i simply check if a returned value of type int or uint is a number?
How can i simply check if a returned value of type int or uint
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Simple:
[UPDATE]
Keep in mind that if
_myValueis of typeintoruint, then(_myValue is Number)will also equate totrue. If you want to know if_myValueis a number that isn’t an integer(int) or unsigned integer (uint), in other words a float, then you can simply modify the conditional as follows:Let’s look at an example: