9 Replies - 330 Views - Last Post: 15 January 2013 - 03:29 AM Rate Topic: -----

#1 ajrodelo  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 23
  • Joined: 14-January 13

help error says ; ecpected

Posted 15 January 2013 - 02:48 AM

hey whats up everybody its is saying ; is expected at the end but i cant find were to put it at all if some one could help me i would really appreciate it
#include <cstdlib>
#include <iostream>

using namespace std;

int main(int argc, char *argv[])
{
	     int choice;
	     cout  << "WELCOME CRIMINALS\n\n";
	     cout  << "Are u ready to comit some crimes and make some MULAH\n";
	     cout  << "1. HELL YES\n";
	     cout  << "2. Naw im cool\n";
	     cout  << "Your Choice";
	     cin   >> choice;
	   
         if(choice == 2 ) {
	     cout  << "\n\n\n FUCKING PUSSY!!";
	     }
	     
	     if(choice == 1 ) { //first condition i.e. HELL YES
	     cout << "\n\n\n Were do u want to go to to rob \n\n";
	     cout << "1. Wallmart \n";
	     cout << "2. Big 5 \n";
	     cout << "3. Target \n";
	     cout << "Your Choice";
	     std :: cin>>choice;
	     
	     if (choice == 1 ) {//walmart
         cout << "\n\n\n You go to walmart at 1:oo am and try to steal a \n";
         cout << "flat screen tv and get caught because there is always cops \n";
         cout << "there u idoit u get locked up and go to jail \n";
         cout << "GAME OVER DOGGY \n\n";
         }
	     
	     
         if (choice == 3) {//target
         cout << "\n\n\n Shit are you crazy you aint robbing target i fucken love target \n";
         cout << "GAME OVER NIGGY \n\n";
          }
	     
	     if(choice == 2) { //2nd condition i.e Big 5
	     cout << "\n\n\n How do u want to do this \n\n";
	     cout << "1. wait for midnight and go hit up the store \n";
	     cout << "2. go early and scope out the place \n";              
	     cin >> choice;
	 
	     if(choice == 1) { //First condition i.e wait for midnight
	     cout << "\n\n\n You drive by the big 5 and see there is no cars \n";
	     cout << "in the parking lot \n";
         cout << "1. Keep driving and go back home \n";
	     cout << "2. pull in to the parking lot \n";
         }
         
	     if(choice == 2) { //come in early scope out big five
	     cout << "\n\n\n You walk in the big 5 and some stupid pot head kid says \n";
	     cout << "Welecome to big 5 good lookin how can i help you \n";
	     cout << "1. fuck you loser \n";
         cout << "2. Ask him if he can show u the shoes \n";
         cout << "3. Pull your pistol out and rob that MUTHA FUCKA \n";
         cin >> choice;   }
         
         if (choice == 1) {//get your ass kicked by leroy
         cout << "\n\n\n The dumb pot head kid kicks the shit out of who would \n";
         cout << "have thought that a gay looking kid like him could punch sooo \n";
         cout << "hard looks like your the loser \n";
         cout << "GAME OVER LOSER \n\n";
       
         if (choice == 2) {//u get a good loot at cameras
         cout << "\n\n\n He takes to the the back and and shows u the shoes \n";
         cout << "you get a good look of things and figure out where all the \n";
         cout << "cameras are at and return to the big 5 at midnight \n";
         }
	     //Now you need to close the braces accordingly
	 
	  }//Closes braces for *

	 	 }//closes braces for $   
	 
	    system("PAUSE");
	    return EXIT_SUCCESS;
	}//closes the main()



Is This A Good Question/Topic? 0
  • +

Replies To: help error says ; ecpected

#2 raghav.naganathan  Icon User is offline

  • Perfectly Squared ;)
  • member icon

Reputation: 408
  • View blog
  • Posts: 1,440
  • Joined: 14-September 12

Re: help error says ; ecpected

Posted 15 January 2013 - 03:08 AM

Can you please post the exact error that you are getting along with the line number?

regards,
Raghav
Was This Post Helpful? 1
  • +
  • -

#3 ajrodelo  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 23
  • Joined: 14-January 13

Re: help error says ; ecpected

Posted 15 January 2013 - 03:12 AM

well i figured it out but i have a diffrent prob now my last choice dosnt come up when i compile and run
    if(choice == 2) { //come in early scope out big five
	     cout << "\n\n\n You walk in the big 5 and some stupid pot head kid says \n";
	     cout << "Welecome to big 5 good lookin how can i help you \n";
	     cout << "1. fuck you loser \n";
         cout << "2. Ask him if he can show u the shoes \n";
         cout << "3. Pull your pistol out and rob that MUTHA FUCKA \n";
         cin >> choice;   }
         
         if (choice == 1) {//get your ass kicked by leroy
         cout << "\n\n\n The dumb pot head kid kicks the shit out of who you would \n";
         cout << "have thought that a gay looking kid like him could punch sooo \n";
         cout << "hard looks like your the loser \n";
         cout << "GAME OVER LOSER \n\n";
       
         if (choice == 2) {//u get a good loot at cameras
         cout << "\n\n\n He takes to the the back and and shows u the shoes \n";
         cout << "you get a good look of things and figure out where all the \n";
         cout << "cameras are at and return to the big 5 at midnight \n";
         }
        
	     //Now you need to close the braces accordingly
	 
	  }//Closes braces for *

	 	 }//closes braces for $   
	 
	    system("PAUSE");
	    return EXIT_SUCCESS;
      }
	}//closes the main()


Was This Post Helpful? 0
  • +
  • -

#4 raghav.naganathan  Icon User is offline

  • Perfectly Squared ;)
  • member icon

Reputation: 408
  • View blog
  • Posts: 1,440
  • Joined: 14-September 12

Re: help error says ; ecpected

Posted 15 January 2013 - 03:14 AM

Try adding a } on line 14 and see if it works.

regards,
Raghav
Was This Post Helpful? 1
  • +
  • -

#5 ajrodelo  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 23
  • Joined: 14-January 13

Re: help error says ; ecpected

Posted 15 January 2013 - 03:16 AM

thanks a lot by the way im really learning a lot just by posting things up here

View Postraghav.naganathan, on 15 January 2013 - 03:14 AM, said:

Try adding a } on line 14 and see if it works.

regards,
Raghav

it gave me an error that says 83 expected declaration before '}' token
Was This Post Helpful? 0
  • +
  • -

#6 raghav.naganathan  Icon User is offline

  • Perfectly Squared ;)
  • member icon

Reputation: 408
  • View blog
  • Posts: 1,440
  • Joined: 14-September 12

Re: help error says ; ecpected

Posted 15 January 2013 - 03:18 AM

Now can you please post your complete code after the modification?

regards,
Raghav
Was This Post Helpful? 1
  • +
  • -

#7 ajrodelo  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 23
  • Joined: 14-January 13

Re: help error says ; ecpected

Posted 15 January 2013 - 03:20 AM

#include <cstdlib>
#include <iostream>

using namespace std;

int main(int argc, char *argv[])
{
	     int choice;
	     cout  << "WELCOME CRIMINALS\n\n";
	     cout  << "Are u ready to comit some crimes and make some MULAH\n";
	     cout  << "1. HELL YES\n";
	     cout  << "2. Naw im cool\n";
	     cout  << "Your Choice";
	     cin   >> choice;
	   
         if(choice == 2 ) {
	     cout  << "\n\n\n FUCKING PUSSY!!";
	     }
	     
	     if(choice == 1 ) { //first condition i.e. HELL YES
	     cout << "\n\n\n Were do u want to go to to rob \n\n";
	     cout << "1. Wallmart \n";
	     cout << "2. Big 5 \n";
	     cout << "3. Target \n";
	     cout << "Your Choice";
	     std :: cin>>choice;
	     
	     if (choice == 1 ) {//walmart
         cout << "\n\n\n You go to walmart at 1:oo am and try to steal a \n";
         cout << "flat screen tv and get caught because there is always cops \n";
         cout << "there u idoit u get locked up and go to jail \n";
         cout << "GAME OVER DOGGY \n\n";
         }
	     
	     
         if (choice == 3) {//target
         cout << "\n\n\n Shit are you crazy you aint robbing target i fucken love target \n";
         cout << "GAME OVER NIGGY \n\n";
          }
	     
	     if(choice == 2) { //2nd condition i.e Big 5
	     cout << "\n\n\n How do u want to do this \n\n";
	     cout << "1. wait for midnight and go hit up the store \n";
	     cout << "2. go early and scope out the place \n";              
	     cin >> choice;
	 
	     if(choice == 1) { //First condition i.e wait for midnight
	     cout << "\n\n\n You drive by the big 5 and see there is no cars \n";
	     cout << "in the parking lot \n";
         cout << "1. Keep driving and go back home \n";
	     cout << "2. pull in to the parking lot \n";
         }
         
	     if(choice == 2) { //come in early scope out big five
	     cout << "\n\n\n You walk in the big 5 and some stupid pot head kid says \n";
	     cout << "Welecome to big 5 good lookin how can i help you \n";
	     cout << "1. fuck you loser \n";
         cout << "2. Ask him if he can show u the shoes \n";
         cout << "3. Pull your pistol out and rob that MUTHA FUCKA \n";
         cin >> choice;   }
         
         if (choice == 1) {//get your ass kicked by leroy
         cout << "\n\n\n The dumb pot head kid kicks the shit out of who you would \n";
         cout << "have thought that a gay looking kid like him could punch sooo \n";
         cout << "hard looks like your the loser \n";
         cout << "GAME OVER LOSER \n\n";
         }
         if (choice == 2) {//u get a good loot at cameras
         cout << "\n\n\n He takes to the the back and and shows u the shoes \n";
         cout << "you get a good look of things and figure out where all the \n";
         cout << "cameras are at and return to the big 5 at midnight \n";
         }
        
	     //Now you need to close the braces accordingly
	 
	  }//Closes braces for *

	 	 }//closes braces for $   
	 
	    system("PAUSE");
	    return EXIT_SUCCESS;
      }
	}//closes the main()

This post has been edited by jimblumberg: 15 January 2013 - 07:41 AM
Reason for edit:: Added missing code tags. Please learn to use them properly.

Was This Post Helpful? 0
  • +
  • -

#8 raghav.naganathan  Icon User is offline

  • Perfectly Squared ;)
  • member icon

Reputation: 408
  • View blog
  • Posts: 1,440
  • Joined: 14-September 12

Re: help error says ; ecpected

Posted 15 January 2013 - 03:24 AM

Well, remove the second last brace, just after return EXIT_SUCCESS

regards,
Raghav
Was This Post Helpful? 1
  • +
  • -

#9 ajrodelo  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 23
  • Joined: 14-January 13

Re: help error says ; ecpected

Posted 15 January 2013 - 03:28 AM

lol thanks again man
Was This Post Helpful? 0
  • +
  • -

#10 raghav.naganathan  Icon User is offline

  • Perfectly Squared ;)
  • member icon

Reputation: 408
  • View blog
  • Posts: 1,440
  • Joined: 14-September 12

Re: help error says ; ecpected

Posted 15 January 2013 - 03:29 AM

Most welcome :)

regards,
Raghav
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1