0
How do I remove or decline user input?
I want the user to only choose between 2 characters: c and t. so how do I exclude other alphabet and numbers.
4 Respuestas
+ 1
Luis remove the email address.
0
Here you go:
https://code.sololearn.com/cvrxu7i8ICU4/#cpp
0
I'm not very experienced with cpp but maybe just set an array of accepted values and do a single if statement to see if array contains user input.
You could either do nothing if user provides invalid input or notify user of invalid input. Either way you should only need to write a line or two.