Hello, I've got some problems in checking whether the input data are numbers (double) or not!
I find that "strtod" will be useful...but as I'm a beginner of C++...I dont understand how to make it...I have no idea at all
I want to check the input of numbers, make sure they are numerical. IF the input isnt numerical, it should prompt for re-entry.
Can anybody generously give me a hand, please?
Thanks in advance!!! >.<
You could write yourself a little template function called getInput or something to that effect which loops until the user enters valid data and prints a message when the user prints something invalid.