let me now how it is and if you need to see code tell me for improvements.
#include <iostream>
#include <cstdio>
#include <cstdlib>
using namespace std;
int main()
{
cout << "ON THIS PROGRAM YOU WILL HAVE THE CHOICES ON WHAT TO DO " << endl << endl << endl;
cout << "Your walking on a rainy dark night, suddenly a lightning flashes and you" << endl;
cout << "see a castle roof inside the forest." << endl << endl;
cout << "Press 1 to go inside the forest. " << endl;
cout << "Press 2 to keep walking home. " << endl;
int choice;
cin >> choice;
switch(choice)
{
case 1:
cout << " you have enter the dark woods of chaos, you now find yourself, " << endl;
cout << " lost inside the forest, you then start walking to the castles door" << endl;
cout << " you find a group of people gathering infront of the castle door, " << endl;
cout << " there yelling that there going to find the source that is keeping " << endl;
cout << " them trap in the dark forest." << endl << endl;
cout << "Press 3 to enter the castle for shelter. " << endl;
cout << "Press 4 to Grab weapons and join the fight. " << endl;
break;
case 2:
cout << " You got home and went to bed thinking what would of " << endl;
cout << " happened if you went to the castle. " << endl;
cout << " <--------------GAME OVER--------------> " << endl;
cin.get();
cin.ignore();
return 0;
}
cin >> choice;
switch(choice)
{
case 3:
cout << " The door is locked, solve the math problem to enter the castle" << endl;
cout << " 5(x - 3) = 35 " << "enter right answear for x to open door." << endl;
break;
case 4:
cout << "you grab a weapon and join the people that were going to war" << endl;
cout << "you walk north into the forest and you find two paths, " << endl;
cout << "but one is blocked with a big giant stone, you go to the path " << endl;
cout << "that is not blocked, sadly there was a giant hole on the way" << endl;
cout << "you go back to the castle " << endl;
cout << " The door is locked, solve the math problem to enter the castle" << endl;
cout << " 5(x - 3) = 35 " << "enter right answear for x to open door." << endl;
break;
}
int x;
cin >> x;
if ( x == 10 )
{
cout << "answear is correct, proceed" << endl << endl;
}
else if ( x != 10 )
{
cout << " Bad answear, the door shots a curse into you " << endl;
cout << " <----------GAME OVER--------------->" << endl;
cin.get();
cin.ignore();
system ("PAUSE");
return 0;
}
cout << " you search the castle, and notice that it's empty, but you see a " << endl;
cout << " nice chest that you aproach." << endl << endl;
cout << "!!!!chest talks to you and asks you a question!!!!!" << endl << endl;
cout << "??????_How many types of flow controll are there_??????" << endl << endl;
int answear;
cin >> answear;
if ( answear == 3 )
{
cout << " chest opens and you find a TNT inside it. " << endl << endl;
cout << " You grab the TNT and go back outside. " << endl << endl;
}
else if ( answear != 3 )
{
cout << " Wrong answear, the door closes you are trap inside forever " << endl;
cout << " <---------------GAME OVER-------------> " << endl;
cin.get();
cin.ignore();
system ("PAUSE");
return 0;
}
cout << "you find no other choice but to grab a weapon and join the fight" << endl << endl;
cout << "you walk north into the forest and you find two paths, " << endl;
cout << "but one is blocked with a big stone, luckily you" << endl;
cout << " have a TNT and you can choice were to go. " << endl << endl;
cout << " 5: Plant TNT destroy stone to go that way. " << endl;
cout << " 6: Follow the path that is open. " << endl << endl;
cin >> choice;
switch (choice)
{
case 5:
cout << " Solve problem to activate TNT for 10 seconds " << endl;
cout << " 5(4x - 3) + 8 = -2 " << endl << endl;
break;
case 6:
cout << "you go to the path that is not blocked, sadly there was a giant hole on the way" << endl;
cout << "you go back to place the TNT on the stone. " << endl << endl;
cout << " Solve problem to activate TNT for 10 seconds " << endl;
cout << " 5(4x - 3) + 8 = -2 " << endl << endl;
break;
}
double a;
cin >> a;
if ( a == 0.25 )
{
cout << " TNT ACTIVATED----------< " << endl;
cout << "10, 9, 8, 7, 6, 5, 4, 3, 2, 1 BOOM!" << endl;
}
else if ( a != 0.25 )
{
cout << " TNT explodes immediately " << endl;
cout << "<--------GAME OVER-------->" << endl;
cin.get();
cin.ignore();
system ("PAUSE");
return 0;
}
cout << "Path is open, when you enter you find out that it's a " << endl;
cout << "demons lair, you are now fighting with a demon. " << endl << endl;
cout << "Solve the problems to attack demon" << endl<< endl;
cout << " 243 * 28 = n " << endl;
cin >> x;
if ( x == 6804 )
{
int d;
d = 150 - 50;
cout << "Your life: " << 50 << endl << "Demons life: " << 150 << endl << endl;
cout << "You attack the demon" << endl << endl;
cout << "Your life: " << 50 << endl << "Demons life: " << d << endl;
}
else if ( x != 6804 )
{
cout << "Demon kills you " << endl;
cout << "<--------GAME OVER-------->" << endl;
cin.get();
cin.ignore();
return 0;
}
cout << " 5 * 4(23) / 3 = x" << endl;
cin >> x;
if ( x == 705 )
{
int d;
d = 100 - 50;
cout << "Your life: " << 50 << endl << "Demons life: " << 100 << endl<< endl;
cout << "You attack the demon" << endl << endl;
cout << "Your life: " << 50 << endl << "Demons life: " << d << endl << endl;
}
else if ( x != 705 )
{
cout << "Demon kills you " << endl;
cout << "<--------GAME OVER-------->" << endl;
cin.get();
cin.ignore();
return 0;
}
cout << " whats the average of 23 + 52 +12: " << endl;
cin >> x;
if ( x == 29 )
{
int d;
d = 50 - 50;
cout << "Your life: " << 50 << endl << "Demons life: " << 50 << endl<< endl;
cout << "You attack the demon" << endl << endl;
cout << "Your life: " << 50 << endl << "Demons life: " << d << endl << endl;
}
else if ( x != 29 )
{
cout << "Demon kills you " << endl;
cout << "<--------GAME OVER-------->" << endl;
cin.get();
cin.ignore();
return 0;
}
cout << "You have killed the demon that was cursing the forest now your able to" << endl;
cout << "exit the dark forest " << endl;
cout << "You went back home happy to be alive <img src='http://public.gamedev.net/public/style_emoticons/<#EMO_DIR#>/biggrin.gif' class='bbc_emoticon' alt=':D' />" << endl << endl;
cout << " CEDITS " << endl;
cout << " Programer: Bernie Ochoa " << endl;
cout << " Story: Bernie Ochoa " << endl;
cout << " Company: Core-Bros " << endl;
cout << " http://corebros.webs.com/ " << endl;
cout << "<------THANKS FOR PLAYING-----> " << endl;
cin.get();
cin.ignore();
return 0;
}
also how do i post my work in my profile? this question was answeared thanks






