Міністерство освіти і науки України
ФАКУЛЬТЕТ ІНФОРМАТИКИ
КАФЕДРА ІНФОРМАЦІЙНИХ УПРАВЛЯЮЧИХ СИСТЕМ ТА ТЕХНОЛОГІЙ
КУРСОВА РОБОТА
Тема:
Інтерактивна система навчання для вивчення англійської мови.
Підписи членів комісії
Зміст
#include <iostream.h>
#include <dos.h>
#include <conio.h>
#include <string.h>
const char numberOfAnswer[] = "nPress 5 for 50/50, 6 phone friend, 7 walk away.nn";
const char numberOfAnswer2[] = "Please enter the number of your choice: ";
const char people1[] = "John";
const char people2[] = "Mary";
const char people3[] = "Paul";
const char people4[] = "Kathy";
const char people5[] = "Greg";
const char people6[] = "Tracy";
const char people7[] = "Peter";
const char people8[] = "Lara";
const char people9[] = "Jason";
const char people0[] = "April";
const char people01[] = "Jeremy";
const char people02[] = "Paula";
const char people03[] = "Chris";
const char people04[] = "Jennifer";
const char people05[] = "Steve";
const char goodAnswer1[] = "nnCorrect!nn";
const char goodAnswer2[] = "nnGreat Job!!nn";
const char goodAnswer3[] = "nnKeep up the good work!nn";
const char goodAnswer4[] = "nnThats right!!nn";
const char goodAnswer5[] = "nnWonderful answer!!!nn";
const char goodAnswer6[] = "nnRight!nn";
const char goodAnswer7[] = "nnYou must have studied. Thats the right answer!nn";
const char goodAnswer8[] = "nnVery good!!!nn";
const char goodAnswer9[] = "nnYoure absolutely, positively correct!nn";
const char goodAnswer0[] = "nnWow!!nn";
const char goodAnswer01[] = "nnExcellent!nn";
const char goodAnswer02[] = "nnFabulous!nn";
const char goodAnswer03[] = "nnRight on!nn";
const char goodAnswer04[] = "nnYoure a genius!nn";
const char goodAnswer05[] = "nnSplendid!nn";
const char badAnswer1[] = "nnIm sorry, thats the wrong answer. :( nn";
const char badAnswer2[] = "nnNope! Thats not it!!!nn";
const char badAnswer3[] = "nnHahaha. You call that an answer?nn";
const char badAnswer4[] = "nnWrong.nn";
const char badAnswer5[] = "nnIm ashamed of you picking that wrong answer!nn";
const char badAnswer6[] = "nnCome on! I know youre smarter than that! :( nn";
const char badAnswer7[] = "nnMaybe you should quit.nn";
const char badAnswer8[] = "nnWell the good news is theres another question ahead!nn";
const char badAnswer9[] = "nnI hope you make a better choice next time!nn";
const char badAnswer0[] = "nnI dont think so.nn";
const char badAnswer01[] = "nnThat aint it.nn";
const char badAnswer02[] = "nnAnother wrong answer.nn";
const char badAnswer03[] = "nnDont do this to me! Wrong answer. :( nn";
const char badAnswer04[] = "nnYou scare me. Wrong!nn";
const char badAnswer05[] = "nnNo no no! Not that one.nn";
const char question1[] = "What color is a dollar bill?n";
const char question2[] = "If you have 3 quarters, you have...n";
const char question3[] = "George Washington cut down what kind of tree?n";
const char question4[] = "If A = B and B = C, then...n";
const char question5[] = "Complete the phrase: Into the valley rode the...n";
const char question6[] = "Who always saved Timmy?n";
const char question7[] = "Whos first gold record was Hard Headed Woman?n";
const char question8[] = "Who was author of Tom Sawyer and Huckleberry Finn?n";
const char question9[] = "What was Shirley Temples real life last name?n";
const char question0[] = "Who plays the Priest in Anne of Green Gables?n";
const char question01[] = "If a Sirloin Steak is cooked rare, it is generally what color in the middle?n";
const char question02[] = "If Coca Cola is applied to an egg shell, the shell turns what color?n";
const char question03[] = "What is the sum of 30 times 30 plus 90 plus 25?n";
const char question04[] = "Who is the voice of Bart Simpson?n";
const char question05[] = "Who was the original Clarke Kent?n";
int yourAnswer;
int yourAnswer1;
char yourName[128];
int counter = 0;
int counter2 = 0;
int correctAnswers = 0;
unsigned long int score;
int walkAway();
void continueProgram();
int playMillionaire();
int fiftyFiftyUsed;
int phoneFriendUsed;
void answer1();
void answer2();
void answer3();
void answer4();
void answer5();
void answer6();
void answer7();
void answer8();
void answer9();
void answer0();
void answer01();
void answer02();
void answer03();
void answer04();
void answer05();
// Beginning of 50/50 functions
void answer1()
{
clrscr(); // Clears the screen
cout << question1; // Prints question1, defined above, to the screen
cout << " 2. Purplen";
cout << "3. Green n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 3)
{
cout << goodAnswer1;
delay(3000);
correctAnswers++; // Increases correctAnswers by one
score = 100; // Sets score to 100
}
if (yourAnswer != 3)
{
cout << badAnswer1;
delay(3000);
score = 0;
walkAway();
}
}
void answer2()
{
clrscr();
cout << question2;
cout << "1. $.75 n";
cout << " 4. $1.00n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 1)
{
cout << goodAnswer2;
delay(3000);
correctAnswers++;
score = 200;
}
if (yourAnswer != 1)
{
cout << badAnswer2;
delay(3000);
score = 0;
walkAway();
}
}
void answer3()
{
clrscr();
cout << question3;
cout << " 2. Cherryn";
cout << " 4. Magnolian";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 2)
{
cout << goodAnswer3;
delay(3000);
correctAnswers++;
score = 300;
}
if (yourAnswer != 2)
{
cout << badAnswer3;
delay(3000);
score = 0;
walkAway();
}
}
void answer4()
{
clrscr();
cout << question1;
cout << "1. A = B + C n";
cout << " 4. A = C n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 4)
{
cout << goodAnswer4;
delay(3000);
correctAnswers++;
score = 500;
}
if (yourAnswer != 3)
{
cout << badAnswer4;
delay(3000);
score = 0;
walkAway();
}
}
void answer5()
{
clrscr();
cout << question5;
cout << "1. 600 n";
cout << "3. 300 n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 1)
{
cout << goodAnswer5;
delay(3000);
correctAnswers++;
score = 1000;
}
if (yourAnswer != 1)
{
cout << badAnswer5;
delay(3000);
score = 0;
walkAway();
}
}
void answer6()
{
clrscr();
cout << question6;
cout << "1. Lassie 2. Old Yellern";
cout << " n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 1)
{
cout << goodAnswer6;
delay(3000);
correctAnswers++;
score = 2000;
}
if (yourAnswer != 1)
{
cout << badAnswer6;
delay(3000);
score = 1000;
walkAway();
}
}
void answer7()
{
clrscr();
cout << question7;
cout << "1. Jerry Lee Lewis n";
cout << " 4. Elvis Presleyn";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 4)
{
cout << goodAnswer7;
delay(3000);
correctAnswers++;
score = 4000;
}
if (yourAnswer != 1)
{
cout << badAnswer7;
delay(3000);
score = 1000;
walkAway();
}
}
void answer8()
{
clrscr();
cout << question8;
cout << " 2. Mark Twainn";
cout << " 4. Edward Furlongn";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 2)
{
cout << goodAnswer8;
delay(3000);
correctAnswers++;
score = 8000;
}
if (yourAnswer != 2)
{
cout << badAnswer8;
delay(3000);
score = 1000;
walkAway();
}
}
void answer9()
{
clrscr();
cout << question9;
cout << "1. Black 2. Templen";
cout << " n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 1)
{
cout << goodAnswer9;
delay(3000);
correctAnswers++;
score = 16000;
}
if (yourAnswer != 1)
{
cout << badAnswer9;
delay(3000);
score = 1000;
walkAway();
}
}
void answer0()
{
clrscr();
cout << question0;
cout << "1. Gilbert Blithe n";
cout << "3. Sedrick Smith n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 3)
{
cout << goodAnswer0;
delay(3000);
correctAnswers++;
score = 32000;
}
if (yourAnswer != 3)
{
cout << badAnswer0;
delay(3000);
score = 1000;
walkAway();
}
}
void answer01()
{
clrscr();
cout << question01;
cout << " 2. Blackn";
cout << "3. Red n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 3)
{
cout << goodAnswer01;
delay(3000);
correctAnswers++;
score = 64000;
}
if (yourAnswer != 3)
{
cout << badAnswer01;
delay(3000);
score = 32000;
walkAway();
}
}
void answer02()
{
clrscr();
cout << question02;
cout << "1. Brown n";
cout << "3. White n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 1)
{
cout << goodAnswer02;
delay(3000);
correctAnswers++;
score = 125000;
}
if (yourAnswer != 1)
{
cout << badAnswer02;
delay(3000);
score = 32000;
walkAway();
}
}
void answer03()
{
clrscr();
cout << question03;
cout << " n";
cout << "3. 1025 4. 1015n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 4)
{
cout << goodAnswer03;
delay(3000);
correctAnswers++;
score = 250000;
}
if (yourAnswer != 4)
{
cout << badAnswer03;
delay(3000);
score = 32000;
walkAway();
}
}
void answer04()
{
clrscr();
cout << question04;
cout << " 2. Nancy Cartwrightn";
cout << "3. Nancy Drew n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 2)
{
cout << goodAnswer04;
delay(3000);
correctAnswers++;
score = 500000;
}
if (yourAnswer != 2)
{
cout << badAnswer04;
delay(3000);
score = 32000;
walkAway();
}
}
void answer05()
{
clrscr();
cout << question05;
cout << "1. Christopher Reeves n";
cout << "3. George Reeves n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 3)
{
cout << goodAnswer05;
delay(3000);
correctAnswers++;
score = 1000000;
}
if (yourAnswer != 3)
{
cout << badAnswer05;
delay(3000);
score = 32000;
walkAway();
}
}
// End of 50/50 functions
int walkAway() // Decides how the program will end
{
delay(3000); // Pauses for 3 seconds
if (correctAnswers >= 1 && correctAnswers < 15)
{
cout << "nn" << yourName <<", you answered " << correctAnswers << "n"; // Prints how many questions answered of
cout << "out of " << counter << " attempted questions.n"; // how many attempted to the screen
cout << "Youve won " << "$" << score << "!";
}
if (correctAnswers < 1) // Executes if correctAnswers is less than 1
{
cout << "nnOh well, maybe next time.nn"; // Prints to screen
score = 0;
cout << "You won " << "$" << score << ". :( nn";
}
if (correctAnswers == 15) // Executes if correctAnswers is equivalent to 10
{
while (counter2 < 10)
{
counter2++;
clrscr();
delay(300);
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
cout << "1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000 1,000,000n";
delay(300);
clrscr();
delay(300);
counter2++; // Increases counter2 by one
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$n";
delay(300);
clrscr();
delay(300);
}
cout << "Congradulations, " << yourName << ".n";
cout << "Youve won $1,000,000!!!nn";
}
cout << "nnTaken from Television Series Who Wants To Be A Millionairen"; // Prints to screen
cout << "Programmed by Gordon C. December 2001nn"; // in any case
return 0;
}
void continueProgram() // Gives user option to continue or quit
{
delay(5000);
clrscr(); // Clears the screen
cout << "Please enter your FIRST name ONLY: ";
cin >> yourName;
delay(500);
clrscr();
cout << "Hello, " << yourName << ". Welcome to...n";
delay(2000);
cout << "3. 1025 4. 1015n";
cout << numberOfAnswer;
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 4)
{
cout << goodAnswer03;
delay(3000);
correctAnswers++;
score = 250000;
}
if (yourAnswer == 1 || yourAnswer == 2 || yourAnswer == 3)
{
cout << badAnswer03;
delay(3000);
score = 32000;
walkAway();
return 0;
}
if (yourAnswer == 5)
{
if (fiftyFiftyUsed == 1)
{
cout << "nSorry 50/50 has already been used!n";
delay(3000);
clrscr();
goto loop02;
}
if (fiftyFiftyUsed != 1)
{
fiftyFiftyUsed = 1;
answer03();
if (yourAnswer != 4)
{
score = 32000;
return 0;
}
}
}
if (yourAnswer == 6)
{
if (phoneFriendUsed == 1)
{
cout << "Sorry, phone a friend has been used!n";
delay(3000);
clrscr();
goto loop02;
}
if (phoneFriendUsed != 1)
{
phoneFriendUsed = 1;
delay(2000);
cout << "Dialing...n";
delay(2000);
cout << "You have been connected to " << people03 << ".n";
cout << people03 << ",n" << question03 << "n";
cout << "1. 1035 2. 1075n";
cout << "3. 1025 4. 1015n";
delay(2000);
cout << "nn" << people03 << ": " << "Im no math expert. I couldnt tell ya. Sorry.n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 4)
{
cout << goodAnswer03;
delay(3000);
correctAnswers++;
score = 250000;
}
if (yourAnswer != 4)
{
cout << badAnswer03;
delay(3000);
score = 32000;
walkAway();
return 0;
}
if (yourAnswer == 7)
{
score = 32000;
walkAway();
return 0;
}
if (yourAnswer < 1 || yourAnswer > 7)
{
cout << badAnswer03;
delay(3000);
score = 32000;
walkAway();
return 0;
}
}
}
if (yourAnswer == 7)
{
walkAway();
return 0;
}
if (yourAnswer != 1 && yourAnswer != 2 && yourAnswer != 3 && yourAnswer != 4 && yourAnswer != 5 && yourAnswer != 6 && yourAnswer != 7)
{
score = 32000;
walkAway();
return 0;
}
clrscr();
counter++;
cout << "Try for $500000nn";
delay(2000);
clrscr();
loop03:
cout << question04;
delay(3000);
cout << "1. Nancy Sinatra 2. Nancy Cartwrightn";
delay(1000);
cout << "3. Nancy Drew 4. Nancy Reagann";
cout << numberOfAnswer;
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 2)
{
cout << goodAnswer04;
delay(3000);
correctAnswers++;
score = 500000;
}
if (yourAnswer == 1 || yourAnswer == 3 || yourAnswer == 4)
{
cout << badAnswer04;
delay(3000);
score = 32000;
walkAway();
return 0;
}
if (yourAnswer == 5)
{
if (fiftyFiftyUsed == 1)
{
cout << "nSorry 50/50 has already been used!n";
delay(3000);
clrscr();
goto loop03;
}
if (fiftyFiftyUsed != 1)
{
fiftyFiftyUsed = 1;
answer04();
if (yourAnswer != 2)
{
score = 32000;
return 0;
}
}
}
if (yourAnswer == 6)
{
if (phoneFriendUsed == 1)
{
cout << "Sorry, phone a friend has been used!n";
delay(3000);
clrscr();
goto loop03;
}
if (phoneFriendUsed != 1)
{
phoneFriendUsed = 1;
delay(2000);
cout << "Dialing...n";
delay(2000);
cout << "You have been connected to " << people04 << ".n";
cout << people04 << ",n" << question04 << "n";
cout << "1. Nancy Sinatra 2. Nancy Cartwrightn";
cout << "3. Nancy Drew 4. Nancy Reagann";
delay(2000);
cout << "nn" << people04 << ": " << "I love that show! Its Nancy Cartwright. 100% sure.n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 2)
{
cout << goodAnswer04;
delay(3000);
correctAnswers++;
score = 500000;
}
if (yourAnswer != 4)
{
cout << badAnswer04;
delay(3000);
score = 32000;
walkAway();
return 0;
}
if (yourAnswer == 7)
{
score = 32000;
walkAway();
return 0;
}
if (yourAnswer < 1 || yourAnswer > 7)
{
cout << badAnswer04;
delay(3000);
score = 32000;
walkAway();
return 0;
}
}
}
if (yourAnswer == 7)
{
score = 32000;
walkAway();
return 0;
}
if (yourAnswer != 1 && yourAnswer != 2 && yourAnswer != 3 && yourAnswer != 4 && yourAnswer != 5 && yourAnswer != 6 && yourAnswer != 7)
{
score = 32000;
walkAway();
return 0;
}
clrscr();
counter++;
cout << "Try for the Grand Prize $1,000,000!!!nn";
delay(3000);
clrscr();
loop04:
cout << question05;
delay(3000);
cout << "1. Christopher Reeves 2. Don Adamsn";
delay(1000);
cout << "3. George Reeves 4. Dean Caann";
cout << numberOfAnswer;
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 3)
{
cout << goodAnswer05;
delay(3000);
correctAnswers++;
score = 1000000;
}
if (yourAnswer == 1 || yourAnswer == 2 || yourAnswer == 4)
{
cout << badAnswer05;
delay(3000);
score = 32000;
walkAway();
return 0;
}
if (yourAnswer == 5)
{
if (fiftyFiftyUsed == 1)
{
cout << "nSorry 50/50 has already been used!n";
delay(3000);
clrscr();
goto loop04;
}
if (fiftyFiftyUsed != 1)
{
fiftyFiftyUsed = 1;
answer05();
if (yourAnswer != 3)
{
score = 32000;
return 0;
}
}
}
if (yourAnswer == 6)
{
if (phoneFriendUsed == 1)
{
cout << "Sorry, phone a friend has been used!n";
delay(3000);
clrscr();
goto loop04;
}
if (phoneFriendUsed != 1)
{
phoneFriendUsed = 1;
delay(2000);
cout << "Dialing...n";
delay(2000);
cout << "You have been connected to " << people05 << ".n";
cout << people05 << ",n" << question05 << "n";
cout << "1. Christopher Reeves 2. Don Adamsn";
cout << "3. George Reeves 4. Dean Caann";
delay(2000);
cout << "nn" << people05 << ": " << "I know Christopher Reeves is well known for that. I think its him. 50% sure.n";
cout << numberOfAnswer2;
cin >> yourAnswer;
if (yourAnswer == 3)
{
cout << goodAnswer05;
delay(3000);
correctAnswers++;
score = 1000000;
}
if (yourAnswer != 3)
{
cout << badAnswer05;
delay(3000);
score = 32000;
walkAway();
return 0;
return 0;
}
}
}
if (yourAnswer == 7)
{
score = 32000;
walkAway();
return 0;
}
if (yourAnswer != 1 && yourAnswer != 2 && yourAnswer != 3 && yourAnswer != 4 && yourAnswer != 5 && yourAnswer != 6 && yourAnswer != 7)
{
score = 32000;
walkAway();
return 0;
}
walkAway();
return 0;
}
int main()
{
clrscr();
cout << "*******************************n";
cout << "* Who Wants To Be *n";
cout << "* A *n";
cout << "* Millionaire?! *n";
cout << "*******************************n";
continueProgram();
}
Приклад скріншоту роботи програми
Скрін 1. Простий текстовий інтерфейс роботи користувача з програмою
Програма має простий інтуїтивний інтерфейс, який схожий на той, що використовували старі ігрові програми - так звані текстові квести. Розібратися з ним не потребує багато зусиль. Ще раз підкреслимо що всі листинги та головний запускаємий модуль знаходяться на дискетці.
Висновки
Результатом нашої роботи є програма яка вчитель англійської мови. Дана програма має досить простий інтерфейс та алгоритмічну структуру. В якості інструменту розробки ми взяли мову програмування C++Builder.
Саме такий вибір дозволив в значній мірі спростити процес розробки та реалізації даного програмного продукту. Відмітимо лише, що дана програма має простий текстовий інтерфейс управління і не потребує попереднього навчання при роботі при роботі з собою.
Література
Касаткин А.И., Вальвачев А.Н. Профессиональное прогрпммирование на языке Си. Мн., 1992. 240 С.
Нейбауэр А. Моя первая программа на С/С++. П., 1995. 368 С.
Бруно Бабэ. Просто и ясно о Borland C++. М., 1996. 400 С.
Шамас Н.К. Основы С++ и обьектно-ориентированного программирования. К., 1996. 448 С.
! | Как писать курсовую работу Практические советы по написанию семестровых и курсовых работ. |
! | Схема написания курсовой Из каких частей состоит курсовик. С чего начать и как правильно закончить работу. |
! | Формулировка проблемы Описываем цель курсовой, что анализируем, разрабатываем, какого результата хотим добиться. |
! | План курсовой работы Нумерованным списком описывается порядок и структура будующей работы. |
! | Введение курсовой работы Что пишется в введении, какой объем вводной части? |
! | Задачи курсовой работы Правильно начинать любую работу с постановки задач, описания того что необходимо сделать. |
! | Источники информации Какими источниками следует пользоваться. Почему не стоит доверять бесплатно скачанным работа. |
! | Заключение курсовой работы Подведение итогов проведенных мероприятий, достигнута ли цель, решена ли проблема. |
! | Оригинальность текстов Каким образом можно повысить оригинальность текстов чтобы пройти проверку антиплагиатом. |
! | Оформление курсовика Требования и методические рекомендации по оформлению работы по ГОСТ. |
→ | Разновидности курсовых Какие курсовые бывают в чем их особенности и принципиальные отличия. |
→ | Отличие курсового проекта от работы Чем принципиально отличается по структуре и подходу разработка курсового проекта. |
→ | Типичные недостатки На что чаще всего обращают внимание преподаватели и какие ошибки допускают студенты. |
→ | Защита курсовой работы Как подготовиться к защите курсовой работы и как ее провести. |
→ | Доклад на защиту Как подготовить доклад чтобы он был не скучным, интересным и информативным для преподавателя. |
→ | Оценка курсовой работы Каким образом преподаватели оценивают качества подготовленного курсовика. |
Курсовая работа | Деятельность Движения Харе Кришна в свете трансформационных процессов современности |
Курсовая работа | Маркетинговая деятельность предприятия (на примере ООО СФ "Контакт Плюс") |
Курсовая работа | Политический маркетинг |
Курсовая работа | Создание и внедрение мембранного аппарата |
Курсовая работа | Социальные услуги |
Курсовая работа | Педагогические условия нравственного воспитания младших школьников |
Курсовая работа | Деятельность социального педагога по решению проблемы злоупотребления алкоголем среди школьников |
Курсовая работа | Карибский кризис |
Курсовая работа | Сахарный диабет |
Курсовая работа | Разработка оптимизированных систем аспирации процессов переработки и дробления руд в цехе среднего и мелкого дробления Стойленского ГОКа |
Курсовая работа | Особенности внимания у детей с задержкой психического развития |
Курсовая работа | Государственное регулирование занятости |
Курсовая работа | Производительность труда, ее измерение и резервы роста на предприятии |
Курсовая работа | Учет и анализ материально-производственных запасов |
Курсовая работа | Наследование по завещанию |
Курсовая работа | Особенности уголовной ответственности и наказания несовершеннолетних |
Курсовая работа | Эксплуатация почтовой связи |
Курсовая работа | Оценка рыночной стоимости объекта недвижимости |
Курсовая работа | Доказательство и доказывание в уголовном процессе |
Курсовая работа | Аудит основных средств |
Курсовая работа | Сюжетно-ролевые игры в детском саду |
Курсовая работа | Приемы работы над развитием связной речи младших школьников |
Курсовая работа | Анализ производительности труда на предприятии |
Курсовая работа | Оценка эффективности инвестиционных проектов |
Курсовая работа | Твердые токсичные отходы промышленности |