WIN.A.Creve
12-08-2002, 07:48 AM
if you want YeS to be accepted use this line of code
#include <ctype.h>
.
.
.
cin >> correct;
correct=toupper(correct)
if (correct == "YES"){
the toupper will change all the character of correct to capital letter so yes, Yes, YeS, YES are all going to be YES
#include <ctype.h>
.
.
.
cin >> correct;
correct=toupper(correct)
if (correct == "YES"){
the toupper will change all the character of correct to capital letter so yes, Yes, YeS, YES are all going to be YES