New course! Every coder should learn Generative AI!
Try a free lesson+ 1
Create a. Program that recognizes letters as errors(or that restricts letters) when input by the user
The program shout only accept digits and restrict any letter input...using c++
1 Answer
+ 1
You could use a while loop to get input... Here's an example:
https://www.delftstack.com/howto/cpp/cpp-input-validation/