Ok, this keeps taking in names until you enter exit as a name:
Code:#include <iostream> #include <string> using namespace std; int main() { char name[256]; main: cout<<"Enter a name: "; cin>> name; cin.ignore(); if( strcmp(name,"exit")==0) return 0; if ( strcmp(name,"Shayne")==0 ) cout<<"Shayne is a twenty fifth dinosaur pagent.\n"; else if ( strcmp(name,"Jamie")==0 ) cout<<".... and so on and so on for like 10 names..\n"; else cout<<"....\n"; cin.get(); goto main; }