I am learning arrays and I have a simple question.
Why isnt my do-while loop working?
You can see the loop in it .Code:#include <iostream.h> int main() { char string[100]; do{ cout << "What is your name?"; cin.getline (string, 100); cout << "\nHello" << string <<".\n"; cout << "Where are you from?"; cin.getline (string, 100); cout << "\nYour from" << string <<"! Cool me too\n"; cout << "What is your favorite sports team"; cin.getline (string, 100); cout << "\nThe" << string <<"! Nah they suck"; } while ( (string != "BYE" ) && (string != "bye" ) ); return 0; }
can you guys please help me



LinkBack URL
About LinkBacks


