Sound/song in this project

Please support our C++ advertiser: Programming Forums - DaniWeb Sister Site
Reply

Join Date: Mar 2006
Posts: 12
Reputation: dors_zone is an unknown quantity at this point 
Solved Threads: 0
dors_zone dors_zone is offline Offline
Newbie Poster

Sound/song in this project

 
0
  #1
Apr 3rd, 2006
#include <iostream>

using namespace std; // allow use of standard names like cin, cout, etc.


int main (void)
{
//variables
char answer1, answer2, answer3, answer4, stall; // capital letters selected by the test taker.
int numberCorrect=0; // to determine the IQ

cout<<" "<<endl;
cout<<" ******************************************************************************"<<endl;
cout<<" * *"<<endl;
cout<<" * @@@ @@ @@@ @@@ @@@@ @@ @ @ @@@@ *"<<endl;
cout<<" * @ @ @ @ @ @ @ @ @ @ @@ @ @ *"<<endl;
cout<<" * @ @ @ @ @@@ @@@ @ @ @ @ @ @ @@@@ *"<<endl;
cout<<" * @ @ @ @ @ @ @ @ @ @ @ @@ @ *"<<endl;
cout<<" * @@@ @@ @ @ @@@ @@@@ @@ @ @ @@@@ *"<<endl;
cout<<" * *"<<endl;
cout<<" ******************************************************************************"<<endl;
cout<<" "<<endl;
cout << "\n The following short quiz consists of 4 questions which will indicate whether";
cout << "\n you are qualified to be a professional. The questions are NOT that difficult.";
cout << "\n \n";
cout<<" "<<endl;


//QUESTION 1
cout << " 1. How do you put a giraffe into a refrigerator?\n";
cout<<" "<<endl;
cout << " A: I do not have a giraffe."<<endl;
cout << " B: Open the refrigerator, put in the giraffe, and close the door."<<endl;
cout << " C: There is no sensible answer to this."<<endl;
cout << " D: You must first go to the zoo and obtain a giraffe.."<<endl;
cout<<" "<<endl;
cout << " Select one answer and enter its capital letter (followed by a carriage return).\n";
cin >> answer1;
cout <<"\n\n The correct answer is B"<< endl<<endl <<endl;
//Question 1 tests whether you tend to do simple things in an overly complicated way.

//QUESTION 2
cout << "2. How do you put an elephant into a refrigerator?" <<endl;
cout<<" "<<endl;
cout << "A: I do not have an elephant."<<endl;
cout << "B: Open the refrigerator, put in the elephant, and close the door."<<endl;
cout << "C: Call any Republican."<<endl;
cout << "D: Open the refrigerator, take out the giraffe, put in the elephant, and close the door."<<endl;
cout<<" "<<endl;
cout << "Select one answer and enter its letter.\n";

cin>> answer2;
cout <<"\n\n The correct answer is D"<< endl<<endl <<endl;
//Question 2 tests your ability to think through the repercussions
// of your previous actions.

//QUESTION 3
cout << "3. The Lion King is hosting an animal conference. All the animals attend except one.";
cout <<" Which animal does not attend?" <<endl;
cout<<" "<<endl;
cout << "A: The ant."<<endl;
cout << "B: The giraffe."<<endl;
cout << "C: The elephant."<<endl;
cout << "D: You are mistaken. No one would disobey the Lion King."<<endl;
cout<<" "<<endl;
cout << "Select one answer and enter its letter.\n";

cin>> answer3;
cout <<"\n\n The correct answer is C. "<<endl;
cout<<" The elephant is in the refrigerator. You just put him in there."<< endl<<endl <<endl;
//Question 3 tests memory. You still have one more chance to show your true abilities.


//QUESTION 4
cout << "4. There is a river you must cross, but it is inhabited by crocodiles."<<endl;
cout <<" You do not have a boat. How do you manage it?" <<endl;
cout<<" "<<endl;
cout << "A: Put an ad in EBay and buy a boat."<<endl;
cout << "B: Jump in the river and swim across."<<endl;
cout << "C: Take a plane and fly across."<<endl;
cout << "D: Sometimes you can't cross every river."<<endl;
cout<<" "<<endl;
cout << "Select one answer and enter its letter.\n";

cin>> answer4;
cout <<"\n\n The correct answer is B."<<endl;
cout << " All the crocodiles are attending the Animal Meeting."<<endl;
cout << " Have you not been listening?"<< endl<<endl <<endl;
//Question 4 tests whether you lean quickly from your mistakes.

//calculate IQ
if (answer1=='B')
numberCorrect++;
if (answer2=='D')
numberCorrect++;
if (answer3=='C')
numberCorrect++;
if (answer4=='B')
numberCorrect++;
if (numberCorrect<=0)
cout << " You are a lame brain."<<endl;
if (numberCorrect==1)
cout << " You are a dim bulb."<<endl;
if (numberCorrect==2)
cout << " You are so-so."<<endl;
if (numberCorrect==3)
cout << " You are pretty smart."<<endl;
if (numberCorrect==4)
cout << " You are a genius."<<endl;

cout <<" Enter any character and <CR> to quit."<<endl;
cin>> stall;

return 0; //successful completion of project
}

This is an Iq test...n did anyone know..how i want to put song on this project...above is the source code. can anyone help me... any song in wav format or others..thanks
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:




Views: 1497 | Replies: 0
Thread Tools Search this Thread



Tag cloud for C++
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC