0

How do I force my program to only accept numbers in turbo C++ ???

6th Apr 2018, 10:24 AM
Mr Doom
2 ответов
+ 1
int input; if (!(std::cin >> input)) std::cerr << "Your input could not be validated, did you provide something else than a number?\n";
6th Apr 2018, 10:30 AM
Timon Paßlick