0
Range variable
Hi guys can anyone give me an idea of how to write a variable for a range of letters. The program is supposed to detect user input and if the input is not an alphabet character it should bring back an error code. Am using if statements for the variables any help is most welcome
2 Réponses
+ 1
ok will check on it thanx
0
First, make sure that cctype is included.
Then, take user input
if(isalpha(c))//c is a char
//ok
else //error