Hello everyone. I am a beginner at programming in C++, and I just recently finished (to an extent) one of my first real large scale programs, a craps game. Now while playing the near finished version, I noticed that if I input a character when I'm supposed to input an integer, it spazzes out, and when I'm supposed to input a character and input an integer on accident, it also spazzes out.
My question is how can I restrict a users input to numbers only or letters only. I'd post my source code, but it's only half commented. Thanks in advance to anyone who helps![]()



LinkBack URL
About LinkBacks



