[php]
#include <iostream>
#include <string>
#include <sstream>
#include <dos.h>
using namespace std;
int main()
{
int thisIsANumber;
char yesOrNo;
char likeShitTacos;
char BelgianOrEggos;
char strawberry;
char syrup;
string ITSASTRING; // empty string, used for transfering variables
string firstname; // second string, used for first name
string lastname; // third string, used for last name
int age; // int, used for age
string randomword;
int favouritenumber;
cout << "Hi, what is your FIRST name?" << endl;
getline (cin,ITSASTRING); // getting the input from this line and inputting it into ITSASTRING
stringstream(ITSASTRING) >> firstname; // transferring data from ITSASTRING to firstname
cout << "Alright " << firstname << " what is your last?";
getline (cin,ITSASTRING); // getting the input from this line and inputting it into ITSASTRING
stringstream(ITSASTRING) >> lastname; // transferring data from ITSASTRING to lastname
cout << "alrighty then " << firstname<<" " <<lastname <<", how old are you?" << endl; // displaying firstname lastname and asking how old
cin >> age; // the usual cin >> age
if (age < 20) { // if age is less than 20 do the following
cout << "Hi " << firstname<< " " <<lastname << ", welcome to my application!\n type some random word!"<< endl;
getline (cin,ITSASTRING);
stringstream(ITSASTRING) >> randomword;
}
else { // age was more than 20 so we do the following
cout << "Hi " << firstname<<" " <<lastname <<" sorry, but you are too old." << endl;
}
cout << "thats the first word that came to your mind? weird...\n"<< endl;
system("cls");
cout << "Enter a number"<<endl;
getline (cin,ITSASTRING);
stringstream(ITSASTRING) >> thisIsANumber;
cout << "was this your favourite number? (y/n)"<<endl;
getline (cin,ITSASTRING);
stringstream(ITSASTRING) >> yesOrNo;
if(yesOrNo == 'y')
{
cout << "oh, well that was an interesting favourite number.\n"<<endl;
}
else if(yesOrNo == 'n')
{
cout << "oh... what is your favourite number?\n"<<endl;
getline (cin,ITSASTRING);
stringstream(ITSASTRING) >> favouritenumber;
}
else
{
cout << "that wasn't an answer, genius"<<endl;
}
cout << "Do you like waffles?!?!?!!? (y/n)\n"<<endl;
getline (cin,ITSASTRING);
stringstream(ITSASTRING) >> likeShitTacos;
if(likeShitTacos == 'y')
{
cout << " I knoww they are awesome!!!! Belgian or Eggos? (b/e)\n"<<endl;
getline (cin,ITSASTRING);
stringstream(ITSASTRING) >> BelgianOrEggos;
if(BelgianOrEggos == 'b')
{
cout << "yeaaah those are the best... with strawberrys and whipped cream right?(y/n)"<<endl;
getline (cin,ITSASTRING);
stringstream(ITSASTRING) >> strawberry;
if(strawberry == 'y')
{
cout << "mmmm waffles with strawberries and whipped cream... mmmmmmmm"<<endl;
}
else if(strawberry == 'n')
{
cout << "ewwwww... You still use syrup though right? (y/n)"<<endl;
getline (cin,ITSASTRING);
stringstream(ITSASTRING) >> syrup;
if(syrup == 'y')
{
cout << "good... I was worried"<<endl;
}
else if(syrup == 'n')
{
cout << "WTF MAN!!! PLAIN WAFFLES?!?!?! YOUR CRAZY"<<endl;
}
else
{
cout << "one more answer and thats it... Your booted off of this I swear."<<endl;
}
}
else
{
cout << "STOP ANSWERING THAT!!!!!!!!!!!!!"<<endl;
}
}
else if(BelgianOrEggos == 'e')
{
cout << "reaally? Eggos more then Belgians? You've clearly never had a belgian waffle before..."<<endl;
}
else
{
cout << "that wasn't an answer, stop saying random letters... it makes me confused"<<endl;
}
}
else if(likeShitTacos == 'n')
{
cout << "Whatt?!?! you don't like waffles? gtfo...\n"<<endl;
}
else
{
cout << "This wasn't a choice, gtfo\n"<<endl;
}
cout << "well, that'll be all for now. I may have a few updates to this fun little game in the future. Maybe in a .exe

"<<endl;
cin.get();
return 0;
}
[/php]
[php]
cout << "Hi " << firstname<< " " <<lastname << ", welcome to my application!\n type some random word!"<< endl;
getline (cin,ITSASTRING);
stringstream(ITSASTRING) >> randomword;
}
else { // age was more than 20 so we do the following
cout << "Hi " << firstname<<" " <<lastname <<" sorry, but you are too old." << endl;
}
cout << "thats the first word that came to your mind? weird...\n"<< endl;
system("cls");
cout << "Enter a number"<<endl;
getline (cin,ITSASTRING);
stringstream(ITSASTRING) >> thisIsANumber;
[/php]
This is where it starts messing up... It uses the same code for here as everywhere else but this is where it messes up... Try running the entire code and you'll see what I mean...