I\'d like to know how to limit an input value to signed decimals using std::cin.
std::cin
If the backing variable of the cin is a number, and the string provided is not a number, the return value is false, so you need a loop:
cin
int someVal; while(!(cin >> someVal)) { cin.reset(); cout << "Invalid value, try again."; }