Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
The Partial fulfillment of Computer
Science course
Project Work on Quiz Programming
Submitted By Submitted
To:
________ __...
Acknowledgement
I am very thankful to my school who provided me the opportunityto
prepare a project and enhancing my pract...
//*******Quiz Game*********
//Consisting of 2 sets with 10 questions in each set
//It also includes 50-50 lifeline
#includ...
void fifty2();
void fifty3();
void fifty4();
void fifty5();
void fifty6();
void fifty7();
void fifty8();
void fifty9();
vo...
void fifty4();
void fifty5();
void fifty6();
void fifty7();
void fifty8();
void fifty9();
void fifty10();
}s2;
long int pt...
if(age>=25&&age<=35)
{
q=1;
}
if(age>35&&age<=45)
{
q=2;
}
switch(q)
{
case 1:s1.set1();
break;
case2:s2.set2();
break;
de...
cout<<”nThis is your eligibility question”;
cout<<”nnn In computer, what is 1 gigabyte?”;
cout<<n(a)1024*2 bytes”<<”t(b)10...
cout<<”n FINISH THE GAME THERE ONLY”;
cout<<”n ********YOU CAN TAKE ONLY THREE HELP LINES*****”;
cout<<”nnn PRESS ENTER TO...
flag++;
s1.fifty1();
}
cout<<”n Please give your answer:-“;
cin>>ans;
strlwr(ans);
t=strcmp(ans,rs);
if(t==0)
{
pts=1000;
...
cout<<”n What do you mean by Hexadecimal in computer?”;
cout<<”n (a) With a base of 16”<<”t(b) With a base of 6”;
}
//****...
{
pts=2000;
gotoxy(50,22);
cout<<” YOUR SCORE IS:-“<<pts;
cout<<”n PRESS ANY KEYY FOR THE NEXT QUESTION”;
getch();
s1.ques...
cout<<”n (a) Christian Barnard”<<”t(b)Wendell Wilkie”;
cout<<”n (c)Williamm Wordsworth”<<”t(d)Charles Darwin”;
char rs[]=”...
cout<<”a UNSUCCESSFULLa”;
}
}
void quiz::fifty3()
{
clrscr();
cout<<”n Who has written the book ‘ONE LIFE’?”;
cout<<”n (a)...
if(w==’y’||w==’Y’)
{
flag++;
s1.fifty4();
}
}
cout<<”n Please give your answer”;
cin>>ans;
strlwr(ans);
t=strcmp(ans,rs);
...
{
clrscr();
cout<<”n Which game is associate with ‘YONEX CUP’?”;
cout<<”n(a) Golf”<<”t(d)Badminton”;
}
*******************...
cout<<”n Please give your answer”;
cin>>ans;
strlwr(ans);
t=strcmp(ans,rs);
if(t==0)
{
pts=5000;
gotoxy(50,22)
cout<<”YOUR...
****************QUESTION 6*****************
void quiz::ques6()
{
clrscr();
cout<<”n Who invented ‘ELECTRIC RAZOR’?”;
cout<...
pts=5000;
gotoxy(50,22)
cout<<”YOUR SCORE IS:-“<<pts;
cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”;
getch();
s1.ques7();
...
cout<<”n(a)A.Catlin”<<”t(b)Charles GoodYear”;
cout<<”n(c)J.Harrison”<<”t(d)Charles Macintosh”;
char rs[]=”d”;
if(flag&It;3...
s1.ques8();
}
else
{
cout<<”a UNSUCCESSFULLa”;
}
}
void quiz::fifty7()
{
clrscr();
cout<<”Who invented ‘WATERPROOF RUBBER’...
if(w==’y’||w==’Y’)
{
flag++;
s1.fifty8();
}
}
}
cout<<”n Please give your answer”;
cin>>ans;
strlwr(ans);
t=strcmp(ans,rs)...
void quiz::fifty8()
{
clrscr();
cout<<”Where is the disease named ‘GLAUCOMA’ is affected in the
body’?”;
cout<<”nt(b)Eyes”...
}
}
cout<<”n Please give your answer”;
cin>>ans;
strlwr(ans);
t=strcmp(ans,rs);
if(t==0)
{
pts=160000;
gotoxy(50,22)
cout<...
}
******************QUESTION 10****************
void quiz::ques10()
{
clrscr();
cout<<”n Who invented ‘TELEPHONE’?”;
cout<...
t=strcmp(ans,rs);
if(t==0)
{
pts=320000;
gotoxy(50,22)
cout<<”YOUR SCORE IS:-“<<pts;
cout<<”n PRESS ANY KEY FOR THE NEXT Q...
void quiz::fifty10()
{
clrscr();
cout<<”Who invented ‘TELEPHONE’?”;
cout<<”nt(a)Albert Einstein”<<”nt(b)Graham Bell”;
}
//...
cout<<”n You have qualified”;
gotoxy(20,10);
cout<<”n********************************”;
cout<<”n**WELCOME TO THIS GRAND QU...
}
******************QUESTION 1****************
void quiz2::ques1()
{
clrscr();
cout<<”n The British Viceroy who took a no....
cin>>ans;
strlwr(ans);
t=strcmp(ans,rs);
if(t==0)
{
pts=1000;
gotoxy(50,22)
cout<<”YOUR SCORE IS:-“<<pts;
cout<<”n PRESS A...
******************QUESTION 2****************
void quiz2::ques2()
{
clrscr();
cout<<”n The name of 3rd
bird sanctuary at bh...
if(t==0)
{
pts=2000;
gotoxy(50,22)
cout<<”YOUR SCORE IS:-“<<pts;
cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”;
getch();
s...
clrscr();
cout<<”n Who is known as the ‘Father of Geometry’ ?”;
cout<<”n(a)Kepler”<<”t(b)Euclid”;
cout<<”n(c)Pythagora”<<”...
cout<<”YOUR SCORE IS:-“<<pts;
cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”;
getch();
s2.ques4();
}
else
{
cout<<”a UNSUCC...
char rs[]=”d”;
if(flag&It;3)
{
flag++
cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”;
cin>>w;
if(w==’y’||w==’Y’)
{
flag++;
s2.f...
}
else
{
cout<<”a UNSUCCESSFULLa”;
}
}
void quiz2::fifty4()
{
clrscr();
cout<<”n How many centuries did Sachin score again...
cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”;
cin>>w;
if(w==’y’||w==’Y’)
{
flag++;
s2.fifty5();
}
}
}
cout<<”n Please give yo...
}
}
void quiz2::fifty6()
{
clrscr();
cout<<”n The disease caused by bacteria in apple is…?”;
cout<<”nt(c)Wild fire disease...
flag++;
s2.fifty6();
}
}
}
cout<<”n Please give your answer”;
cin>>ans;
strlwr(ans);
t=strcmp(ans,rs);
if(t==0)
{
pts=2000...
clrscr();
cout<<”n Blood calcium level can be increased by the administration of?”;
cout<<”nt(b)Parathormone”<<”nt(c)Thyro...
}
}
cout<<”n Please give your answer”;
cin>>ans;
strlwr(ans);
t=strcmp(ans,rs);
if(t==0)
{
pts=40000;
gotoxy(50,22)
cout<<...
cout<<”nt(c)6”<<”nt(d)4”;
}
******************QUESTION 8****************
void quiz2::ques8()
{
clrscr();
cout<<”n Ezra Cup...
cin>>ans;
strlwr(ans);
t=strcmp(ans,rs);
if(t==0)
{
pts=80000;
gotoxy(50,22)
cout<<”YOUR SCORE IS:-“<<pts;
cout<<”n PRESS ...
******************QUESTION 9****************
void quiz2::ques9()
{
clrscr();
cout<<”n The headquarters of ILO is located i...
{
pts=160000;
gotoxy(50,22)
cout<<”YOUR SCORE IS:-“<<pts;
cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”;
getch();
s2.ques1...
cout<<”n What is October 8th
celebrated for…?”;
cout<<”n(a)Army Day”<<”t(b)U.N.O Day”;
cout<<”n(c)Airforce Day”<<”t(d)Navy...
clrscr();
cout<<”/n******************************************”;
cout<<”/nCONGRATULATIONS YOU WIN”;
cout<<”n***************...
Bibliography
 google.com
 Wikipedia.com
 Together With Book
 meritnation.com
THE END
C++ class 12 cbse quiz programming (Compiled using Turbo C++)
Upcoming SlideShare
Loading in …5
×
Upcoming SlideShare
Quiz using C++
Next
Download to read offline and view in fullscreen.

5

Share

Download to read offline

C++ class 12 cbse quiz programming (Compiled using Turbo C++)

Download to read offline

It's basically the project that u need to submit to the external examiner for the cbse class 12 boards exam. This one is on the topic of Quiz Programming. It is compiled using Turbo C++. All the header files are included along with an acknowledgement and a cover page too.

Related Books

Free with a 30 day trial from Scribd

See all

C++ class 12 cbse quiz programming (Compiled using Turbo C++)

  1. 1. The Partial fulfillment of Computer Science course Project Work on Quiz Programming Submitted By Submitted To: ________ ______ (Computer Teacher)
  2. 2. Acknowledgement I am very thankful to my school who provided me the opportunityto prepare a project and enhancing my practical skill s regarding business firm. I am equally thankful to my teacher, Mr. _____________. He gave me moral support and guided me in different matters regarding the topic. He had been very kind and clearing my doubts. Last but not the least, I would like to thank my parents who helped me in gathering different information, collecting data and guiding me time in making this project. I’d like to recognize these special people for providing me in every manner to make this project a unique and success.
  3. 3. //*******Quiz Game********* //Consisting of 2 sets with 10 questions in each set //It also includes 50-50 lifeline #include<iostream.h> #include<ctype.h> #include<string.h> #include<conio.h> #include<stdio.h> #include<stdlib.h> class quiz { public: void set1(); void ques1(); void ques2(); void ques3(); void ques4(); void ques5(); void ques6(); void ques7(); void ques8(); void ques9(); void ques10(); void fifty1();
  4. 4. void fifty2(); void fifty3(); void fifty4(); void fifty5(); void fifty6(); void fifty7(); void fifty8(); void fifty9(); void fifty10(); }s1; public: void set2(); void ques1(); void ques2(); void ques3(); void ques4(); void ques5(); void ques6(); void ques7(); void ques8(); void ques9(); void ques10(); void fifty1(); void fifty2(); void fifty3();
  5. 5. void fifty4(); void fifty5(); void fifty6(); void fifty7(); void fifty8(); void fifty9(); void fifty10(); }s2; long int pts; int t=0,flag=0; char ans[1],w; ************MAIN PART************ void main() { clrscr(); int age,q; char name[30]; gotoxy(20,10); cout<<”n THIS IS A QUIZ GAME”; cout<<”nnn FIRST ANSWER THE ELIGIBLE QUESTION TO PLAY THE GAME”; cout<<”n Enter the game:-“; gets(name); cout<<”n Enter the age:-“; cin>>age;
  6. 6. if(age>=25&&age<=35) { q=1; } if(age>35&&age<=45) { q=2; } switch(q) { case 1:s1.set1(); break; case2:s2.set2(); break; default:cout<<”aError”; } getch(); } //************END MAIN************ //************SET 1************* void quiz::set1() { clrscr();
  7. 7. cout<<”nThis is your eligibility question”; cout<<”nnn In computer, what is 1 gigabyte?”; cout<<n(a)1024*2 bytes”<<”t(b)1024*1024*1024 bytes”; cout<<”n(c)1024*3 bytes”<<”t(d)NONE OF THESE”; char rs[]=”b”; cout<<”n Enter your answer:-“; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { clrscr(); cout<<”n You have qualified”; gotoxy(20,10); cout<<”n********************************”; cout<<”n**WELCOME TO THIS GRAND QUIZ SHOW**”; cout<<”n**************************************”; cout<<”nnn HERE YOU WILL BE ASKED A QUESTION & FOUR OPTIONS”; cout<<”n WILL BE THERE, IN WHICH THREE ARE WRONG AND ONLY ONE”; cout<<”n IS CORRECT.YOU HAVE TO GIVE THE CORRECT ANSWER”; cout<<”n YOU HAVE A 50-50 HELP LINE IN WHICH THERE WILL BE”; cout<<n ONLY TWO OPTIONS OF WHICH ONE IS CORRECT.YOU”; cout<<”n HAVE TO GIVE THE CORRECT ANSWER.WRONG ANSWER MEANS YOU “;
  8. 8. cout<<”n FINISH THE GAME THERE ONLY”; cout<<”n ********YOU CAN TAKE ONLY THREE HELP LINES*****”; cout<<”nnn PRESS ENTER TO START THE GAME”; getch(); s1.ques1(); } else { cout<<”a UNSUCCESSFUL a”; cout<<”nntt BETTER LUCK NEXT TIME”; getch(); } } //*****************************QUESTION 1**************************** void quiz::ques1() { clrscr(); cout<<”n What do you mean by hexadecimal in computer?”; cout<<”n (a) With a base of 16”<<”t(b)With a base of 6”; cout<<”n (c) With a base of 8”<<”t(d) NONE OF THESE”; char rs[]=”a”; cout<<”n DO YOU WANT 50/50 LIFELINE (Y/N)”; cin>>w; if(w==’Y’||w==’y’) {
  9. 9. flag++; s1.fifty1(); } cout<<”n Please give your answer:-“; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=1000; gotoxy(50,22); cout<<”YOUR SCORE:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s1.ques2(); } else { cout<<”a UNSUCCESSFULa”; getch(); } } void quiz::fifty1() { clrscr();
  10. 10. cout<<”n What do you mean by Hexadecimal in computer?”; cout<<”n (a) With a base of 16”<<”t(b) With a base of 6”; } //***********************QUESTION 2************************* void quiz::ques2() { clrscr(); cout<<”n Who has written the book ‘DIVINE LIFE’?”; cout<<”n (a) Charles Dickens”<<”t (b)Dante Alighieri”; cout<<”n (c) Swami Sivananda”<<”t(d) Karl Max”; char rs[]=”c”; cout<<”n DO YOU WANT 50-50 LIFELINE (Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s1.fifty2(); } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0)
  11. 11. { pts=2000; gotoxy(50,22); cout<<” YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEYY FOR THE NEXT QUESTION”; getch(); s1.ques3(); } else { cout<<”aUNSUCCESSFULa; } } void quiz::fifty2() { clrscr(); cout<<”n Who has written the book ‘THE DIVINE LIFE’?” cout<<”n (c)Swami Sivananda”<<t(d)Karl Marx”; } ******************QUESTION 3******************* void quiz::ques3() { clrscr(); cout<<”n Who has written the book ‘ONE LIFE’?”;
  12. 12. cout<<”n (a) Christian Barnard”<<”t(b)Wendell Wilkie”; cout<<”n (c)Williamm Wordsworth”<<”t(d)Charles Darwin”; char rs[]=”a”; cout<<”n DO YOU WANT 50-5- LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s1.fifty3(); } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=3000; gotoxy(50,22); cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s1.ques4(); } else {
  13. 13. cout<<”a UNSUCCESSFULLa”; } } void quiz::fifty3() { clrscr(); cout<<”n Who has written the book ‘ONE LIFE’?”; cout<<”n (a) Christian Barnard”<<”n (c) William Wordsworth”; } *******************QUESTION 4************************ void quiz::ques4() { clrscr(); cout<<”n Which game is associated with ‘YONEX CUP’?”; cout<<”n (a) Golf”<<:t(b)Baseball”; cout<<”n (c) Yatch Racing”<<”t(d)Badminton”; char rs[]=”d”; if(flag&It;3) { flag++; cout<<”n DO YOU WANT 50-50 LIFELINE (Y/N)”; cin>>w;
  14. 14. if(w==’y’||w==’Y’) { flag++; s1.fifty4(); } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=5000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s1.ques5(); } else { cout<<”a UNSUCCESSFULLa”; } } void quiz::fifty4()
  15. 15. { clrscr(); cout<<”n Which game is associate with ‘YONEX CUP’?”; cout<<”n(a) Golf”<<”t(d)Badminton”; } *******************QUESTION 5******************** void quiz::ques5() { clrscr(); cout<<”n Who invented ‘Mechanical Clock”?; cout<<”n (a) C.Huygens”<<”t(b)Samuel Colt”; cout<<”n ©Hsing and Ling-Tsan”<<”t(d) Wilhelm Roentgen”; char rs[]=”c”; if(flag&It;3) { cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s1.fifty5(); } }
  16. 16. cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=5000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s1.ques5(); } else { cout<<”a UNSUCCESSFULLa”; } } void quiz::fifty5(); { clrscr(); cout<<”n Who invented ‘MECHANICAL CLOCK’?”; cout<<”nt(b)Samuel Colt”<<”n(c)Hsing and Ling-Tsan”; }
  17. 17. ****************QUESTION 6***************** void quiz::ques6() { clrscr(); cout<<”n Who invented ‘ELECTRIC RAZOR’?”; cout<<”n (a)K.G.Gillet”<<”t(b)Viscose Co.”; cout<<”n(c)L.C.Young”<<”t(d)Col.J.Schick”; char rs[]=”d”; if(flag&It;3) { cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s1.fifty6(); } } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) {
  18. 18. pts=5000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s1.ques7(); } else { cout<<”a UNSUCCESSFULLa”; } } void quiz::fifty6() { clrscr(); cout<<”n Who invented ‘ELECTRIC CLOCK’?”; cout<<”nt(b)Viscose Co.”<<”nt(d)Col.J.Schick”; } ******************QUESTION 7**************** void quiz::ques7() { clrscr(); cout<<”n Who invented ‘WATERPROOF RUBBER’?”;
  19. 19. cout<<”n(a)A.Catlin”<<”t(b)Charles GoodYear”; cout<<”n(c)J.Harrison”<<”t(d)Charles Macintosh”; char rs[]=”d”; if(flag&It;3) { cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s1.fifty7(); } } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=40000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch();
  20. 20. s1.ques8(); } else { cout<<”a UNSUCCESSFULLa”; } } void quiz::fifty7() { clrscr(); cout<<”Who invented ‘WATERPROOF RUBBER’?”; cout<<”nt(b)Charles GoodYear”<<”nt(d)Charles Macintosh”; } ******************QUESTION 8**************** void quiz::ques8() { clrscr(); cout<<”n Where the disease named ‘GLAUCOMA’ is affected in the body’?”; cout<<”n(a)Skin”<<”t(b)Eyes”; cout<<”n(c)Spleen”<<”t(d)blood”; char rs[]=”d”; if(flag&It;3) { cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w;
  21. 21. if(w==’y’||w==’Y’) { flag++; s1.fifty8(); } } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=80000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s1.ques9(); } else { cout<<”a UNSUCCESSFULLa”; } }
  22. 22. void quiz::fifty8() { clrscr(); cout<<”Where is the disease named ‘GLAUCOMA’ is affected in the body’?”; cout<<”nt(b)Eyes”<<”nt(c)Spleen”; } ******************QUESTION 9**************** void quiz::ques9() { clrscr(); cout<<”n When was Abraham Lincoln re-elected as president of USA’?”; cout<<”n(a)1864”<<”t(b)1814”; cout<<”n(c)1865”<<”t(d)1819”; char rs[]=”d”; if(flag&It;3) { cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s1.fifty9(); }
  23. 23. } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=160000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s1.ques10(); } else { cout<<”a UNSUCCESSFULLa”; } } void quiz::fifty9() { clrscr(); cout<<”When was Abraham Lincoln re-elected as the president of USA’?”; cout<<”nt(a)1864”<<”nt(c)1865”;
  24. 24. } ******************QUESTION 10**************** void quiz::ques10() { clrscr(); cout<<”n Who invented ‘TELEPHONE’?”; cout<<”n(a)Albert Einstein”<<”t(b)Graham Bell”; cout<<”n(c)J.Harrison”<<”t(d)Charles Macintosh”; char rs[]=”d”; if(flag&It;3) { cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s1.fifty10(); } } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans);
  25. 25. t=strcmp(ans,rs); if(t==0) { pts=320000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); clrscr(); cout<<”n************************************************”; cout<<”n CONGRATS YOU HAVE COMPLETED”; cout<<”n*****************************”; } else { cout<<”UNSUCCESSFULLa”; } } s1.ques8(); } else { cout<<”a UNSUCCESSFULLa”; } }
  26. 26. void quiz::fifty10() { clrscr(); cout<<”Who invented ‘TELEPHONE’?”; cout<<”nt(a)Albert Einstein”<<”nt(b)Graham Bell”; } //*****************End Of Set 1***************** //*****************SET 2****************** void quiz::set2() { clrscr(); cout<<”n This is your eligibility question”; cout<<”nnn The provisional Government Of India was formet at?”; cout<<”n(a)Tokyo”<<”t(b)Singapore”; cout<<”n(c)Jakarta”<<”t(d)Kuala Lumpur”; char rs[]=”b”; cout<<”nEnter you answer:-“; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { clrscr();
  27. 27. cout<<”n You have qualified”; gotoxy(20,10); cout<<”n********************************”; cout<<”n**WELCOME TO THIS GRAND QUIZ SHOW**”; cout<<”n**************************************”; cout<<”nnn HERE YOU WILL BE ASKED A QUESTION & FOUR OPTIONS”; cout<<”n WILL BE THERE, IN WHICH THREE ARE WRONG AND ONLY ONE”; cout<<”n IS CORRECT.YOU HAVE TO GIVE THE CORRECT ANSWER”; cout<<”n YOU HAVE A 50-50 HELP LINE IN WHICH THERE WILL BE”; cout<<n ONLY TWO OPTIONS OF WHICH ONE IS CORRECT.YOU”; cout<<”n HAVE TO GIVE THE CORRECT ANSWER.WRONG ANSWER MEANS YOU “; cout<<”n FINISH THE GAME THERE ONLY”; cout<<”n ********YOU CAN TAKE ONLY THREE HELP LINES*****”; cout<<”nnn PRESS ENTER TO START THE GAME”; getch(); s2.ques1(); } else { cout<<”a UNSUCCESSFUL a”; getch(); }
  28. 28. } ******************QUESTION 1**************** void quiz2::ques1() { clrscr(); cout<<”n The British Viceroy who took a no. of measures for preserving ”; cout<<”n ancient buildings and monuments in India was…?”; cout<<”n(a)Lord Rippon”<<”t(b)Lord Curzon”; cout<<”n(c)Lord Minton”<<”t(d)Lord Irwin”; char rs[]=”d”; if(flag&It;3) { flag++ cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s2.fifty1(); } } } cout<<”n Please give your answer”;
  29. 29. cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=1000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s2.ques2(); } else { cout<<”a UNSUCCESSFULLa”; } } void quiz2::fifty1() { clrscr(); cout<<”n The British Viceroy who took a no. of measures”; cout<<”n preserving ancient buildings and monuments in India was…?”; cout<<”nt(b)Lord Curzon”<<”nt(d)Lord Irwin”; }
  30. 30. ******************QUESTION 2**************** void quiz2::ques2() { clrscr(); cout<<”n The name of 3rd bird sanctuary at bharatpur is..??”; cout<<”n(a)Bhansrod Garh Sanctuary”<<”t(b)Darrah Sanctuary”; cout<<”n(c)Ghana Sanctuary”<<”t(d)Ghatprabha Sanctuary”; char rs[]=”d”; if(flag&It;3) { flag++ cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s2.fifty2(); } } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs);
  31. 31. if(t==0) { pts=2000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s2.ques3(); } else { cout<<”a UNSUCCESSFULLa”; } } void quiz2::fifty2() { clrscr(); cout<<”The name of the 3rd bird sanctuary if bharatpur is…?”; cout<<”nt(a)Bhansrod Garh Sanctuary”<<”nt(c)Ghana Sanctuary”; } ******************QUESTION 3**************** void quiz2::ques3() {
  32. 32. clrscr(); cout<<”n Who is known as the ‘Father of Geometry’ ?”; cout<<”n(a)Kepler”<<”t(b)Euclid”; cout<<”n(c)Pythagora”<<”t(d)Newton”; char rs[]=”d”; if(flag&It;3) { flag++ cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s2.fifty3(); } } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=3000; gotoxy(50,22)
  33. 33. cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s2.ques4(); } else { cout<<”a UNSUCCESSFULLa”; } } void quiz2::fifty3() { clrscr(); cout<<”Who is known as the ‘Father Of Geometry’?”; cout<<”nt(b)Euclid”<<”nt(c)Pythagoras”; } ******************QUESTION 4**************** void quiz2::ques4() { clrscr(); cout<<”n How many centuries did Sachin score against Kenya?”; cout<<”n(a)2”<<”t(b)3”; cout<<”n(c)6”<<”t(d)4”;
  34. 34. char rs[]=”d”; if(flag&It;3) { flag++ cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s2.fifty4(); } } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=5000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s2.ques5();
  35. 35. } else { cout<<”a UNSUCCESSFULLa”; } } void quiz2::fifty4() { clrscr(); cout<<”n How many centuries did Sachin score against Kenya?”; cout<<”nt(c)6”<<”nt(d)4”; } ******************QUESTION 5**************** void quiz2::ques5() { clrscr(); cout<<”The disease caused in apple by bacteria is..?”; cout<<”n(a)Wild Fire disease”<<”t(b)Black rot disease”; cout<<”n(c)Ring disease”<<”t(d)Fire bright disease”; char rs[]=”d”; if(flag&It;3) { flag++
  36. 36. cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s2.fifty5(); } } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=10000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s2.ques5(); } else { cout<<”a UNSUCCESSFULLa”;
  37. 37. } } void quiz2::fifty6() { clrscr(); cout<<”n The disease caused by bacteria in apple is…?”; cout<<”nt(c)Wild fire disease”<<”nt(d)Fire blight disease”; } ******************QUESTION 6**************** void quiz2::ques6() { clrscr(); cout<<”Blood calcium level can be increased by administration of..?”; cout<<”n(a)Glucagon”<<”t(b)Parathormone”; cout<<”n(c)Thyroxine”<<”t(d)Calcitonin”; char rs[]=”d”; if(flag&It;3) { flag++ cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) {
  38. 38. flag++; s2.fifty6(); } } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=20000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s2.ques7(); } else { cout<<”a UNSUCCESSFULLa”; } } void quiz2::fifty6() {
  39. 39. clrscr(); cout<<”n Blood calcium level can be increased by the administration of?”; cout<<”nt(b)Parathormone”<<”nt(c)Thyroxine”; } ******************QUESTION 7**************** void quiz2::ques7() { clrscr(); cout<<”n An element E from a solid oxide which dissolves in water to ?”; cout<<”n give an acidic solution, the element E is…?”; cout<<”n(a)H”<<”t(b)P”; cout<<”n(c)Mg”<<”t(d)N”; char rs[]=”d”; if(flag&It;3) { flag++ cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s2.fifty7(); }
  40. 40. } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=40000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s2.ques8(); } else { cout<<”a UNSUCCESSFULLa”; } } void quiz2::fifty7() { clrscr(); cout<<”n An element E from a solid oxide which dissolves in water?”; cout<<”n to give an acidic solution, the element E is…?”
  41. 41. cout<<”nt(c)6”<<”nt(d)4”; } ******************QUESTION 8**************** void quiz2::ques8() { clrscr(); cout<<”n Ezra Cup is associated with which sports?”; cout<<”n(a)Rowing”<<”t(b)Golf”; cout<<”n(c)Air races”<<”t(d)Polo”; char rs[]=”d”; if(flag&It;3) { flag++ cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s2.fifty8(); } } } cout<<”n Please give your answer”;
  42. 42. cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=80000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s2.ques9(); } else { cout<<”a UNSUCCESSFULLa”; } } void quiz2::fifty8() { clrscr(); cout<<”n Ezra Cup is associated with which sports?”; cout<<”nt(c)Air races”<<”nt(d)Polo”; }
  43. 43. ******************QUESTION 9**************** void quiz2::ques9() { clrscr(); cout<<”n The headquarters of ILO is located in…?”; cout<<”n(a)Geneve”<<”t(b)The hague”; cout<<”n(c)New York”<<”t(d)Rome”; char rs[]=”d”; if(flag&It;3) { flag++ cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s2.fifty9(); } } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0)
  44. 44. { pts=160000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts; cout<<”n PRESS ANY KEY FOR THE NEXT QUESTION”; getch(); s2.ques10(); } else { cout<<”a UNSUCCESSFULLa”; } } void quiz2::fifty9() { clrscr(); cout<<”n The headquarters of ILO is located in…?”; cout<<”nt(a)”<<”nt(d)The Hague”; } ******************QUESTION 10**************** void quiz2::ques10() { clrscr();
  45. 45. cout<<”n What is October 8th celebrated for…?”; cout<<”n(a)Army Day”<<”t(b)U.N.O Day”; cout<<”n(c)Airforce Day”<<”t(d)Navy Day”; char rs[]=”d”; if(flag&It;3) { flag++ cout<<”n DO YOU WANT 50-50 LIFELINE(Y/N)”; cin>>w; if(w==’y’||w==’Y’) { flag++; s2.fifty10(); } } } cout<<”n Please give your answer”; cin>>ans; strlwr(ans); t=strcmp(ans,rs); if(t==0) { pts=320000; gotoxy(50,22) cout<<”YOUR SCORE IS:-“<<pts;
  46. 46. clrscr(); cout<<”/n******************************************”; cout<<”/nCONGRATULATIONS YOU WIN”; cout<<”n********************************”; } else { cout<<”a UNSUCCESSFULLa”; } } void quiz2::fifty10() { clrscr(); cout<<”n What is October 8th celebrated for..?”; cout<<”nt(c)Airforce Day”<<”nt(d)Navy Day”; } //****************END OF SET 2******************* //***************END OF QUIZ*******************
  47. 47. Bibliography  google.com  Wikipedia.com  Together With Book  meritnation.com
  48. 48. THE END
  • nirmalsoni1234

    Jan. 14, 2020
  • KarmaGyalpo

    Dec. 28, 2019
  • madhurkant

    Dec. 20, 2017
  • HitendraDixit

    Dec. 25, 2016
  • ChetanSharma306

    Dec. 6, 2016

It's basically the project that u need to submit to the external examiner for the cbse class 12 boards exam. This one is on the topic of Quiz Programming. It is compiled using Turbo C++. All the header files are included along with an acknowledgement and a cover page too.

Views

Total views

2,084

On Slideshare

0

From embeds

0

Number of embeds

8

Actions

Downloads

70

Shares

0

Comments

0

Likes

5

×