SlideShare a Scribd company logo
1 of 31
Computer Science
Project
Ashwin Francis
2014-2015
1. Certificate
2. Declaration
3. Acknowledgement
4. Introduction to c++
5. Introduction to Project
6. Codings
7. Outputs
8. Bibliography
This is to certify that the project entitled “QUIZ
GAME” is a record of bonafide work carried out by
“Ashwin Francis 12th
A”.In partial fulfilment of the
requirements in COMPUTER SCIENCE prescribed by
CBSE for CBSE BOARD 2014-2015 in the school
Kendriya Vidyalaya Gole Market,New Delhi 110001.
DATE PRINCIPAL
INTERNAL EXTERNAL
EXAMINER EXAMINER
We hereby declare that the project work entitled
“QUIZ GAME“. Submitted to KENDRIYA VIDYALAYA
GOLE MARKET, NEW DELHI for theSubject of
“COMPUTER SCIENCE“. Under the guidance of
Mrs.Neera Singhal, PGT(COMP Sc.), Is a record of
original work done by us.We further Declare that this
project record or any part of this has not been
Submitted elsewhere for any other class.
DATE MEMBERS
PLACE
We wish to express our sincere thanks to Mr.
DHIR SINGH Principal,Kendriya Vidyalaya Gole
Market, New Delhi for guiding us to cause the
successful outcome of this project work.
We wish to express our deep & profound sense of
gratitude to our guide/teacher Mrs.Neera Singhal,
PGT(COMP Sc.), For her expert help &valuable
guidance, comments and suggestions.
We also place on record, our sincere Gratitude to
one and all who ,Directly or Indirectly ,Have Lent
their helping hand in this venture.
C++ is a programming Language Developed by Bjarne Stroustrup. It was
originally named as C with classes, was renamed as C++ in 1983.It is regarded
as an intermediate-level language, as it comprises both high-level and low-level
language features. Its application domains include systems software,
application software, device drivers, embedded software, highperformance
server and client applications, and entertainment software such as video
games. C++ continues to be used and is one of the preferred programming
languages to develop professional applications
The Features of C++ as a Language
Now that all the necessary theory has been covered, now it is possible to
explain what C++ has to offer as a programming language. C++....
• ...is an open source ISO-standardized language.
For a time, C++ had no official standard and was maintained by a defacto
standard, however since 1998, C++ is standardized by a committee of
the ISO.
• ...is a compiled language.
C++ compiles directly to a machine's native code, allowing it to be one
of the fastest languages in the world, if optimized.
• ...supports both static and dynamic type checking.
C++ allows type conversions to be checked either at compile-time or
at run-time, again offering another degree of flexibility. Most C++ type
checking is, however, static.
• ...is portable.
As one of the most frequently used languages in the world and as an open
language, C++ has a wide range of compilers that run on many different
platforms that support it.Code that exclusively uses C++'s standard library will
run on many platforms with few to no changes.
Quiz game is a very popular General Knowledge Game. The quiz game
increases the IQ knowledgeof the player. Itis used to check the knowledge
within us.
The provided sourcecode is the simple Quiz game programmed implementing
C language. In this program severalquestion are provided to the player. The
players are provided with 4 options in it. Player is all need to choice the
suitable option from the 4 option available in the screen. The player needs to
type either A, B, C, or D according to the suitable answer provided in it.
The player will scorethe points with each correctanswer provided.
#include<iostream.h>
#include<fstream.h>
#include<ctype.h>
#include<string.h>
#include<conio.h>
#include<stdlib.h>
#include<stdio.h>
classquiz
{
public:
voidset1();
voidques1();
voidques2();
voidques3();
voidques4();
voidques5();
voidfifty1();
voidfifty2();
voidfifty3();
voidfifty4();
voidfifty5();
}s1;
longintpts;
intt=0,flag=0;
char ans[1],w;
fstreamf1;
voidmain()
{
clrscr();
intn;
char name[30],ch;
fstreamf1;
cout<<"nttttTHISIS A QUIZ GAMEnntCREATEDBY nttAMAN ROYnttSHOBHIT
GUPTAnttVIMALKUMARnnPRESSENTER TO PLAY";
getch();
menu:
clrscr();
cout<<"ttttMENUn1.Playgamen2.View game datannEnteryourchoice:";
cin>>n;
if(n==2)
{
f1.open("Game.txt",ios::in);
if(!f1)
{
cout<<"No DatannnPRESSENTER";
getch();
goto menu;
}
else
{
f1.seekg(0);
while(!f1.eof())
{
f1.get(ch);
cout<<ch;
}
f1.close();
cout<<"nnnPRESSENTER";
getch();
goto menu;
}
}
else
{
cout<<"nnnFIRSTANSWERTHE ELIGIBLE QUESTION TO PLAY THE GAME";
cout<<"nnEnterthe name:-";
gets(name);
f1.open("Game.txt",ios::out);
f1<<name<<" ";
getch();
s1.set1();
label:
cout<<"nntttTHANKYOUFORUSING THIS SOFTWAREnt THIS SOFTWAREIS CREATED BY THE
STUDENTS OF K. V.GOLE MARKET.nttttPLEASEDONTCOPY";
getch();
}
}
//*************** END OF MAIN **********************
//******** SET 1
voidquiz::set1()
{
clrscr();
cout<<"n Thisisyour eligibilityquestion";
cout<<"nnnnIncomputer,whatis1gigabyte?";
cout<<"n(a)1024*2 bytes"<<"t(b)1024*1024*1024 bytes";
cout<<"n(c)1024*3 bytes"<<"t(d)NONEOFTHESE";
char rs[]="b";
cout<<"nEnteryouranswer:- ";
cin>>ans;
t=strcmp(ans,rs);
if(t==0)
{
clrscr();
cout<<"nYouhave qualified";
cout<<"n***********************************";
cout<<"n**WELCOME TO THIS GRAND QUIZ SHOW**";
cout<<"n***********************************";
cout<<"nnnnHEREYOU WILL BE ASKEDA QUESTION & FOUR OPTIONS";
cout<<"nWILL BE THERE, IN WHICH THREE ARE WRONG ANDONLY ONE";
cout<<"nISCORRECT.YOU HAVE TO GIVE THE CORRECT ANSWER";
cout<<"nYOU HAVEA 50 - 50 HELP LINE IN WHICH THERE WILL BE ";
cout<<"nONLYTWO OPTIONSOFWHICH ONLY ONEIS CORRECT. YOU";
cout<<"nHAVETO GIVE THE CORRECT ANSWER.ANYWRONGANSWERMEANSYOU ";
cout<<"nFINISHTHE GAME THERE ONLY. "; cout<<"n******** YOU CAN TAKEONLY THREE HELP
LINES *********";
cout<<"nnnnnPRESSENTERTOSTART THE GAME ";
getch();
s1.ques1();
}
else
{
cout<<"aWRONG ANSWER!!!!a";
cout<<"nnttBETTER LUCK NEXT TIME ";
getch();
}
}
//************** QUESTION 1
voidquiz::ques1()
{
clrscr();
cout<<"nWhatdo you meanbyHexadecimal incomputer?";
cout<<"n(a)Withabase of 16"<<"t(b)Witha base of 6";
cout<<"n(c)Withabase of 8"<<"t(d)NONEOFTHESE";
char rs[]="a";
cout<<"nDO YOU WANT 50/50 LIFELINE (Y/N) ";
cin>>w;
if(w=='Y'||w=='y')
{
flag++;
s1.fifty1();
}
cout<<"n Please give youranswer:- ";
cin>>ans;
t=strcmp(ans,rs);
if(t==0)
{
pts=1000;
cout<<" YOUR SCORE IS:- "<<pts;
f1<<"n"<<pts;
f1.close();
cout<<"nPRESSANYKEY FORTHE NEXT QUESTION ";
getch();
s1.ques2();
}
else
{
cout<<"aWRONG ANSWER!!!!a";
getch();
}
}
voidquiz::fifty1()
{
clrscr();
cout<<"nWhatdo you meanbyHexadecimal incomputer?";
cout<<"n(a)Withabase of 16"<<"t(b)Witha base of 6";
}
//******** QUESTION 2
voidquiz::ques2()
{
clrscr();
cout<<"nWhohas writtenthe book'DIVINELIFE?";
cout<<"n(a)CharlesDickens"<<"t(b)Dante Alighieri";
cout<<"n(c)Swami Sivananda"<<"t(d)Karl Marx";
char rs[]="c";
cout<<"nDO YOU WANT 50/50 LIFELINE (Y/N)";
cin>>w;
if(w=='Y'||w=='y')
{
flag++;
s1.fifty2();
}
cout<<"n Please give youranswer";
cin>>ans;
t=strcmp(ans,rs);
if(t==0)
{
pts=2000;
cout<<" YOUR SCORE IS:- "<<pts;
f1.open("Game.txt",ios::app);
f1<<"n"<<pts;
f1.close();
cout<<"nPRESSANYKEY FORTHE NEXT QUESTION ";
getch();
s1.ques3();
}
else
{
cout<<"aWRONG ANSWER!!!!a";
}
}
voidquiz::fifty2()
{
clrscr();
cout<<"nWhohas writtenthe book'DIVINELIFE?";
cout<<"n(c)Swami Sivananda"<<"t(d)Karl Marx";
}
//******Question3
voidquiz::ques3()
{
clrscr();
cout<<"nWhohas writtenthe book'ONELIFE'?";
cout<<"n(a)ChristianBarnard"<<"t(b)Wendell Wilkie";
cout<<"n(c)WilliamWordsworth"<<"t(d)CharlesDarwin";
char rs[]="a";
cout<<"nDO YOU WANT 50/50 LIFELINE(Y/N)";
cin>>w;
if(w=='Y'||w=='y')
{
flag++;
s1.fifty3();}
cout<<"n Please give youranswer";
cin>>ans;
t=strcmp(ans,rs);
if(t==0) {
pts=3000;
cout<<" YOUR SCORE IS:- "<<pts;
cout<<"nPRESSANYKEY FORTHE NEXT QUESTION ";
f1.open("Game.txt",ios::app);
f1<<"n"<<pts;
f1.close();
getch();
s1.ques4();
}
else
{
cout<<"aWRONG ANSWER!!!!a";
}
}
voidquiz::fifty3()
{
clrscr();
cout<<"nWhohas writtenthe book'ONELIFE'?";
cout<<"n(a)ChristianBarnard"<<"n(c)WilliamWordsworth";
}
//**********Question 4
voidquiz::ques4()
{
clrscr();
cout<<"nWhichgame is associate with'YONEXCUP'?";
cout<<"n(a)Golf"<<"t(b)Baseball";
cout<<"n(c)YatchRacing"<<"t(d)Badminton";
char rs[]="d";
if(flag<3)
{
flag++;
cout<<"nDO YOU WANT 50/50 LIFELINE(Y/N)";
cin>>w;
if(w=='Y'||w=='y')
{
flag++;
s1.fifty4();
}
}
cout<<"n Please give youranswer";
cin>>ans;
t=strcmp(ans,rs);
if(t==0)
{
pts=5000;
cout<<" YOUR SCORE IS :- "<<pts;
cout<<"nPRESSANYKEY FORTHE NEXT QUESTION ";
f1.open("Game.txt",ios::app);
f1<<"n"<<pts;
f1.close();
getch();
s1.ques5();
}
else
{
cout<<"aWRONG ANSWER!!!!a";
}
}
voidquiz::fifty4()
{
clrscr();
cout<<"nWhichgame is associate with 'YONEXCUP'?";
cout<<"n(a)Golf"<<"t(d)Badminton";
}
//Question5
voidquiz::ques5()
{
clrscr();
cout<<"nWhoinvented'MECHANICALCLOCK'?";
cout<<"n(a)C.Hugyenst(b)SamuelColt";
cout<<"n(c)HsingandLing-Tsant(d)WilhelmRoentgen";
char rs[]="c";
if(flag<3)
{
cout<<"nDO YOU WANT 50/50 LIFELINE(Y/N)";
cin>>w;
if(w=='Y'||w=='y')
{
flag++;
s1.fifty5();
}
}
cout<<"n Please give youranswer";
cin>>ans;
t=strcmp(ans,rs);
if(t==0)
{
pts=10000;
cout<<" YOUR SCORE IS:- "<<pts;
f1.open("Game.txt",ios::app);
f1<<"n"<<pts;
f1.close();
getch();
clrscr();
cout<<"nttt**********************************************";
cout<<"ntttCONGRATULATIONSYOUHAVECOMPLETED THE FULL SET ";
cout<<"nttt**********************************************";
}
else
{
cout<<"aWRONG ANSWER!!!!a";
}
}
voidquiz::fifty5()
{
clrscr();
cout<<"nWhoinvented'MECHANICALCLOCK'?";
cout<<"nt(b)Samuel Coltn(c)HsingandLing-Tsan";
}
HELP FROM INTERNET
INFORMATION FROM BOOKS
HELP FROM TEACHERS
12th CBSE Computer Science Project
12th CBSE Computer Science Project
12th CBSE Computer Science Project
12th CBSE Computer Science Project
12th CBSE Computer Science Project
12th CBSE Computer Science Project
12th CBSE Computer Science Project
12th CBSE Computer Science Project

More Related Content

What's hot

Library Management Project (computer science) class 12
Library Management Project (computer science) class 12Library Management Project (computer science) class 12
Library Management Project (computer science) class 12RithuJ
 
BANK MANAGEMENT INVESTIGATORY PROJECT CLASS 12TH
BANK MANAGEMENT INVESTIGATORY PROJECT CLASS 12THBANK MANAGEMENT INVESTIGATORY PROJECT CLASS 12TH
BANK MANAGEMENT INVESTIGATORY PROJECT CLASS 12THSHAJUS5
 
Class 12th Physics Investigatory Project for CBSE on ERRORS
Class 12th Physics Investigatory Project for CBSE on ERRORSClass 12th Physics Investigatory Project for CBSE on ERRORS
Class 12th Physics Investigatory Project for CBSE on ERRORSRanjan Lohia
 
12th CBSE Computer Science Project
12th CBSE Computer Science Project12th CBSE Computer Science Project
12th CBSE Computer Science ProjectAshwin Francis
 
Chemistry Investigatory Project on content of cold drinks available in market...
Chemistry Investigatory Project on content of cold drinks available in market...Chemistry Investigatory Project on content of cold drinks available in market...
Chemistry Investigatory Project on content of cold drinks available in market...EligetiVishnu
 
Computer Science Investigatory Project Class 12
Computer Science Investigatory Project Class 12Computer Science Investigatory Project Class 12
Computer Science Investigatory Project Class 12Self-employed
 
Determination of The Contents of Cold Drinks
Determination of The Contents of Cold DrinksDetermination of The Contents of Cold Drinks
Determination of The Contents of Cold DrinksProf. Dr. K. Adisesha
 
Class 12 Physics Investigatory Project Work, Practical- study of various logi...
Class 12 Physics Investigatory Project Work, Practical- study of various logi...Class 12 Physics Investigatory Project Work, Practical- study of various logi...
Class 12 Physics Investigatory Project Work, Practical- study of various logi...Kendriya Vidyalaya
 
verification of logic gates cbse class 12
verification of logic gates cbse class 12verification of logic gates cbse class 12
verification of logic gates cbse class 12Kirthi Kirthu
 
COMPUTER SCIENCE INVESTIGATORY PROJECT ON FOOTBALL GAME AND SCORE MANAGEMENT ...
COMPUTER SCIENCE INVESTIGATORY PROJECT ON FOOTBALL GAME AND SCORE MANAGEMENT ...COMPUTER SCIENCE INVESTIGATORY PROJECT ON FOOTBALL GAME AND SCORE MANAGEMENT ...
COMPUTER SCIENCE INVESTIGATORY PROJECT ON FOOTBALL GAME AND SCORE MANAGEMENT ...pankajkumbara
 
Physics investigatory project class 12th.pdf
Physics investigatory project class 12th.pdfPhysics investigatory project class 12th.pdf
Physics investigatory project class 12th.pdfAtharvGupta31
 
Physics investigatory project for class 12
Physics investigatory project for class 12Physics investigatory project for class 12
Physics investigatory project for class 12Kavita Kulkarni
 
Chemistry Investigatory Project - CBSE Class 12
Chemistry Investigatory Project - CBSE Class 12Chemistry Investigatory Project - CBSE Class 12
Chemistry Investigatory Project - CBSE Class 12NandanRamesh2
 
Chemistry investigatory project
Chemistry investigatory projectChemistry investigatory project
Chemistry investigatory projectAbhinav Kumar
 
Study of adulterants in food stuff
Study of adulterants in food stuffStudy of adulterants in food stuff
Study of adulterants in food stuffSwaroop Puhan
 
computer science with python project for class 12 cbse
computer science with python project for class 12 cbsecomputer science with python project for class 12 cbse
computer science with python project for class 12 cbsemanishjain598
 
To study the Presence of Oxalate Ions in Guava Fruit at different stages of R...
To study the Presence of Oxalate Ions in Guava Fruit at different stages of R...To study the Presence of Oxalate Ions in Guava Fruit at different stages of R...
To study the Presence of Oxalate Ions in Guava Fruit at different stages of R...VanshPatil7
 
Computer science project.pdf
Computer science project.pdfComputer science project.pdf
Computer science project.pdfHarshitSachdeva17
 
CHEMISTRY PROJECT FOR CLASS 12TH
CHEMISTRY PROJECT FOR CLASS 12THCHEMISTRY PROJECT FOR CLASS 12TH
CHEMISTRY PROJECT FOR CLASS 12THSaiyed Belal Abbas
 

What's hot (20)

Library Management Project (computer science) class 12
Library Management Project (computer science) class 12Library Management Project (computer science) class 12
Library Management Project (computer science) class 12
 
BANK MANAGEMENT INVESTIGATORY PROJECT CLASS 12TH
BANK MANAGEMENT INVESTIGATORY PROJECT CLASS 12THBANK MANAGEMENT INVESTIGATORY PROJECT CLASS 12TH
BANK MANAGEMENT INVESTIGATORY PROJECT CLASS 12TH
 
Class 12th Physics Investigatory Project for CBSE on ERRORS
Class 12th Physics Investigatory Project for CBSE on ERRORSClass 12th Physics Investigatory Project for CBSE on ERRORS
Class 12th Physics Investigatory Project for CBSE on ERRORS
 
12th CBSE Computer Science Project
12th CBSE Computer Science Project12th CBSE Computer Science Project
12th CBSE Computer Science Project
 
Chemistry Investigatory Project on content of cold drinks available in market...
Chemistry Investigatory Project on content of cold drinks available in market...Chemistry Investigatory Project on content of cold drinks available in market...
Chemistry Investigatory Project on content of cold drinks available in market...
 
Computer Science Investigatory Project Class 12
Computer Science Investigatory Project Class 12Computer Science Investigatory Project Class 12
Computer Science Investigatory Project Class 12
 
Determination of The Contents of Cold Drinks
Determination of The Contents of Cold DrinksDetermination of The Contents of Cold Drinks
Determination of The Contents of Cold Drinks
 
Class 12 Physics Investigatory Project Work, Practical- study of various logi...
Class 12 Physics Investigatory Project Work, Practical- study of various logi...Class 12 Physics Investigatory Project Work, Practical- study of various logi...
Class 12 Physics Investigatory Project Work, Practical- study of various logi...
 
verification of logic gates cbse class 12
verification of logic gates cbse class 12verification of logic gates cbse class 12
verification of logic gates cbse class 12
 
COMPUTER SCIENCE INVESTIGATORY PROJECT ON FOOTBALL GAME AND SCORE MANAGEMENT ...
COMPUTER SCIENCE INVESTIGATORY PROJECT ON FOOTBALL GAME AND SCORE MANAGEMENT ...COMPUTER SCIENCE INVESTIGATORY PROJECT ON FOOTBALL GAME AND SCORE MANAGEMENT ...
COMPUTER SCIENCE INVESTIGATORY PROJECT ON FOOTBALL GAME AND SCORE MANAGEMENT ...
 
Physics investigatory project class 12th.pdf
Physics investigatory project class 12th.pdfPhysics investigatory project class 12th.pdf
Physics investigatory project class 12th.pdf
 
Physics investigatory project for class 12
Physics investigatory project for class 12Physics investigatory project for class 12
Physics investigatory project for class 12
 
Chemistry Investigatory Project - CBSE Class 12
Chemistry Investigatory Project - CBSE Class 12Chemistry Investigatory Project - CBSE Class 12
Chemistry Investigatory Project - CBSE Class 12
 
Chemistry investigatory project
Chemistry investigatory projectChemistry investigatory project
Chemistry investigatory project
 
Study of adulterants in food stuff
Study of adulterants in food stuffStudy of adulterants in food stuff
Study of adulterants in food stuff
 
computer science with python project for class 12 cbse
computer science with python project for class 12 cbsecomputer science with python project for class 12 cbse
computer science with python project for class 12 cbse
 
To study the Presence of Oxalate Ions in Guava Fruit at different stages of R...
To study the Presence of Oxalate Ions in Guava Fruit at different stages of R...To study the Presence of Oxalate Ions in Guava Fruit at different stages of R...
To study the Presence of Oxalate Ions in Guava Fruit at different stages of R...
 
Computer science project.pdf
Computer science project.pdfComputer science project.pdf
Computer science project.pdf
 
CHEMISTRY PROJECT FOR CLASS 12TH
CHEMISTRY PROJECT FOR CLASS 12THCHEMISTRY PROJECT FOR CLASS 12TH
CHEMISTRY PROJECT FOR CLASS 12TH
 
Computer Investgatort Project (HOTEL MANAGEMENT SYSTEM)
Computer Investgatort Project (HOTEL MANAGEMENT SYSTEM)Computer Investgatort Project (HOTEL MANAGEMENT SYSTEM)
Computer Investgatort Project (HOTEL MANAGEMENT SYSTEM)
 

Similar to 12th CBSE Computer Science Project

Computer Project For Class XII Topic - The Snake Game
Computer Project For Class XII Topic - The Snake Game Computer Project For Class XII Topic - The Snake Game
Computer Project For Class XII Topic - The Snake Game Pritam Samanta
 
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015Windows Developer
 
OpenCL Programming 101
OpenCL Programming 101OpenCL Programming 101
OpenCL Programming 101Yoss Cohen
 
Implementing OpenCL support in GEGL and GIMP
Implementing OpenCL support in GEGL and GIMPImplementing OpenCL support in GEGL and GIMP
Implementing OpenCL support in GEGL and GIMPlgworld
 
How to build Kick Ass Games in the Cloud
How to build Kick Ass Games in the CloudHow to build Kick Ass Games in the Cloud
How to build Kick Ass Games in the CloudChris Schalk
 
Fullstack workshop
Fullstack workshopFullstack workshop
Fullstack workshopAssaf Gannon
 
Ronak Kachhawa , BCA Third Year
Ronak Kachhawa , BCA Third YearRonak Kachhawa , BCA Third Year
Ronak Kachhawa , BCA Third YearDezyneecole
 
Introduction to Raspberry Pi and GPIO
Introduction to Raspberry Pi and GPIOIntroduction to Raspberry Pi and GPIO
Introduction to Raspberry Pi and GPIOKris Findlay
 
Open CL For Haifa Linux Club
Open CL For Haifa Linux ClubOpen CL For Haifa Linux Club
Open CL For Haifa Linux ClubOfer Rosenberg
 
Engineer Engineering Software
Engineer Engineering SoftwareEngineer Engineering Software
Engineer Engineering SoftwareYung-Yu Chen
 
Kinect v2 Introduction and Tutorial
Kinect v2 Introduction and TutorialKinect v2 Introduction and Tutorial
Kinect v2 Introduction and TutorialTsukasa Sugiura
 
ma project
ma projectma project
ma projectAisu
 
Increase testability with code seams
Increase testability with code seamsIncrease testability with code seams
Increase testability with code seamsLlewellyn Falco
 

Similar to 12th CBSE Computer Science Project (20)

Computer Project For Class XII Topic - The Snake Game
Computer Project For Class XII Topic - The Snake Game Computer Project For Class XII Topic - The Snake Game
Computer Project For Class XII Topic - The Snake Game
 
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
 
OpenCL Programming 101
OpenCL Programming 101OpenCL Programming 101
OpenCL Programming 101
 
Implementing OpenCL support in GEGL and GIMP
Implementing OpenCL support in GEGL and GIMPImplementing OpenCL support in GEGL and GIMP
Implementing OpenCL support in GEGL and GIMP
 
C++ Kasirul Rashtawi Institute.pdf
C++ Kasirul Rashtawi Institute.pdfC++ Kasirul Rashtawi Institute.pdf
C++ Kasirul Rashtawi Institute.pdf
 
How to build Kick Ass Games in the Cloud
How to build Kick Ass Games in the CloudHow to build Kick Ass Games in the Cloud
How to build Kick Ass Games in the Cloud
 
Fullstack workshop
Fullstack workshopFullstack workshop
Fullstack workshop
 
Kivy for you
Kivy for youKivy for you
Kivy for you
 
computer shop
computer shopcomputer shop
computer shop
 
ELAVARASAN.pdf
ELAVARASAN.pdfELAVARASAN.pdf
ELAVARASAN.pdf
 
Ronak Kachhawa , BCA Third Year
Ronak Kachhawa , BCA Third YearRonak Kachhawa , BCA Third Year
Ronak Kachhawa , BCA Third Year
 
Introduction to Raspberry Pi and GPIO
Introduction to Raspberry Pi and GPIOIntroduction to Raspberry Pi and GPIO
Introduction to Raspberry Pi and GPIO
 
Open CL For Haifa Linux Club
Open CL For Haifa Linux ClubOpen CL For Haifa Linux Club
Open CL For Haifa Linux Club
 
Kubernetes debug like a pro
Kubernetes debug like a proKubernetes debug like a pro
Kubernetes debug like a pro
 
Engineer Engineering Software
Engineer Engineering SoftwareEngineer Engineering Software
Engineer Engineering Software
 
Kinect v2 Introduction and Tutorial
Kinect v2 Introduction and TutorialKinect v2 Introduction and Tutorial
Kinect v2 Introduction and Tutorial
 
ma project
ma projectma project
ma project
 
Increase testability with code seams
Increase testability with code seamsIncrease testability with code seams
Increase testability with code seams
 
Telephone directory
Telephone directoryTelephone directory
Telephone directory
 
Synopsis tic tac toe
Synopsis tic tac toeSynopsis tic tac toe
Synopsis tic tac toe
 

Recently uploaded

Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application ) Sakshi Ghasle
 
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...RKavithamani
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3JemimahLaneBuaron
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Educationpboyjonauth
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppCeline George
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...Marc Dusseiller Dusjagr
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxSayali Powar
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionSafetyChain Software
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Krashi Coaching
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Sapana Sha
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactdawncurless
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docxPoojaSen20
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxmanuelaromero2013
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdfSoniaTolstoy
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdfQucHHunhnh
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 

Recently uploaded (20)

Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application )
 
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Education
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website App
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory Inspection
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docx
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptx
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 
Staff of Color (SOC) Retention Efforts DDSD
Staff of Color (SOC) Retention Efforts DDSDStaff of Color (SOC) Retention Efforts DDSD
Staff of Color (SOC) Retention Efforts DDSD
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 

12th CBSE Computer Science Project

  • 2. 1. Certificate 2. Declaration 3. Acknowledgement 4. Introduction to c++ 5. Introduction to Project 6. Codings 7. Outputs 8. Bibliography
  • 3. This is to certify that the project entitled “QUIZ GAME” is a record of bonafide work carried out by “Ashwin Francis 12th A”.In partial fulfilment of the requirements in COMPUTER SCIENCE prescribed by CBSE for CBSE BOARD 2014-2015 in the school Kendriya Vidyalaya Gole Market,New Delhi 110001. DATE PRINCIPAL INTERNAL EXTERNAL EXAMINER EXAMINER
  • 4. We hereby declare that the project work entitled “QUIZ GAME“. Submitted to KENDRIYA VIDYALAYA GOLE MARKET, NEW DELHI for theSubject of “COMPUTER SCIENCE“. Under the guidance of Mrs.Neera Singhal, PGT(COMP Sc.), Is a record of original work done by us.We further Declare that this project record or any part of this has not been Submitted elsewhere for any other class. DATE MEMBERS PLACE
  • 5. We wish to express our sincere thanks to Mr. DHIR SINGH Principal,Kendriya Vidyalaya Gole Market, New Delhi for guiding us to cause the successful outcome of this project work. We wish to express our deep & profound sense of gratitude to our guide/teacher Mrs.Neera Singhal, PGT(COMP Sc.), For her expert help &valuable guidance, comments and suggestions. We also place on record, our sincere Gratitude to one and all who ,Directly or Indirectly ,Have Lent their helping hand in this venture.
  • 6. C++ is a programming Language Developed by Bjarne Stroustrup. It was originally named as C with classes, was renamed as C++ in 1983.It is regarded as an intermediate-level language, as it comprises both high-level and low-level language features. Its application domains include systems software, application software, device drivers, embedded software, highperformance server and client applications, and entertainment software such as video games. C++ continues to be used and is one of the preferred programming languages to develop professional applications The Features of C++ as a Language Now that all the necessary theory has been covered, now it is possible to explain what C++ has to offer as a programming language. C++.... • ...is an open source ISO-standardized language. For a time, C++ had no official standard and was maintained by a defacto standard, however since 1998, C++ is standardized by a committee of the ISO. • ...is a compiled language. C++ compiles directly to a machine's native code, allowing it to be one of the fastest languages in the world, if optimized. • ...supports both static and dynamic type checking. C++ allows type conversions to be checked either at compile-time or at run-time, again offering another degree of flexibility. Most C++ type checking is, however, static. • ...is portable.
  • 7. As one of the most frequently used languages in the world and as an open language, C++ has a wide range of compilers that run on many different platforms that support it.Code that exclusively uses C++'s standard library will run on many platforms with few to no changes.
  • 8. Quiz game is a very popular General Knowledge Game. The quiz game increases the IQ knowledgeof the player. Itis used to check the knowledge within us. The provided sourcecode is the simple Quiz game programmed implementing C language. In this program severalquestion are provided to the player. The players are provided with 4 options in it. Player is all need to choice the suitable option from the 4 option available in the screen. The player needs to type either A, B, C, or D according to the suitable answer provided in it. The player will scorethe points with each correctanswer provided.
  • 10. fstreamf1; voidmain() { clrscr(); intn; char name[30],ch; fstreamf1; cout<<"nttttTHISIS A QUIZ GAMEnntCREATEDBY nttAMAN ROYnttSHOBHIT GUPTAnttVIMALKUMARnnPRESSENTER TO PLAY"; getch(); menu: clrscr(); cout<<"ttttMENUn1.Playgamen2.View game datannEnteryourchoice:"; cin>>n; if(n==2) { f1.open("Game.txt",ios::in); if(!f1) { cout<<"No DatannnPRESSENTER"; getch(); goto menu; }
  • 11. else { f1.seekg(0); while(!f1.eof()) { f1.get(ch); cout<<ch; } f1.close(); cout<<"nnnPRESSENTER"; getch(); goto menu; } } else { cout<<"nnnFIRSTANSWERTHE ELIGIBLE QUESTION TO PLAY THE GAME"; cout<<"nnEnterthe name:-"; gets(name); f1.open("Game.txt",ios::out); f1<<name<<" "; getch(); s1.set1(); label: cout<<"nntttTHANKYOUFORUSING THIS SOFTWAREnt THIS SOFTWAREIS CREATED BY THE STUDENTS OF K. V.GOLE MARKET.nttttPLEASEDONTCOPY";
  • 12. getch(); } } //*************** END OF MAIN ********************** //******** SET 1 voidquiz::set1() { clrscr(); cout<<"n Thisisyour eligibilityquestion"; cout<<"nnnnIncomputer,whatis1gigabyte?"; cout<<"n(a)1024*2 bytes"<<"t(b)1024*1024*1024 bytes"; cout<<"n(c)1024*3 bytes"<<"t(d)NONEOFTHESE"; char rs[]="b"; cout<<"nEnteryouranswer:- "; cin>>ans; t=strcmp(ans,rs); if(t==0) { clrscr(); cout<<"nYouhave qualified"; cout<<"n***********************************"; cout<<"n**WELCOME TO THIS GRAND QUIZ SHOW**"; cout<<"n***********************************"; cout<<"nnnnHEREYOU WILL BE ASKEDA QUESTION & FOUR OPTIONS"; cout<<"nWILL BE THERE, IN WHICH THREE ARE WRONG ANDONLY ONE"; cout<<"nISCORRECT.YOU HAVE TO GIVE THE CORRECT ANSWER"; cout<<"nYOU HAVEA 50 - 50 HELP LINE IN WHICH THERE WILL BE ";
  • 13. cout<<"nONLYTWO OPTIONSOFWHICH ONLY ONEIS CORRECT. YOU"; cout<<"nHAVETO GIVE THE CORRECT ANSWER.ANYWRONGANSWERMEANSYOU "; cout<<"nFINISHTHE GAME THERE ONLY. "; cout<<"n******** YOU CAN TAKEONLY THREE HELP LINES *********"; cout<<"nnnnnPRESSENTERTOSTART THE GAME "; getch(); s1.ques1(); } else { cout<<"aWRONG ANSWER!!!!a"; cout<<"nnttBETTER LUCK NEXT TIME "; getch(); } } //************** QUESTION 1 voidquiz::ques1() { clrscr(); cout<<"nWhatdo you meanbyHexadecimal incomputer?"; cout<<"n(a)Withabase of 16"<<"t(b)Witha base of 6"; cout<<"n(c)Withabase of 8"<<"t(d)NONEOFTHESE"; char rs[]="a"; cout<<"nDO YOU WANT 50/50 LIFELINE (Y/N) "; cin>>w; if(w=='Y'||w=='y') { flag++;
  • 14. s1.fifty1(); } cout<<"n Please give youranswer:- "; cin>>ans; t=strcmp(ans,rs); if(t==0) { pts=1000; cout<<" YOUR SCORE IS:- "<<pts; f1<<"n"<<pts; f1.close(); cout<<"nPRESSANYKEY FORTHE NEXT QUESTION "; getch(); s1.ques2(); } else { cout<<"aWRONG ANSWER!!!!a"; getch(); } } voidquiz::fifty1() { clrscr(); cout<<"nWhatdo you meanbyHexadecimal incomputer?"; cout<<"n(a)Withabase of 16"<<"t(b)Witha base of 6"; }
  • 15. //******** QUESTION 2 voidquiz::ques2() { clrscr(); cout<<"nWhohas writtenthe book'DIVINELIFE?"; cout<<"n(a)CharlesDickens"<<"t(b)Dante Alighieri"; cout<<"n(c)Swami Sivananda"<<"t(d)Karl Marx"; char rs[]="c"; cout<<"nDO YOU WANT 50/50 LIFELINE (Y/N)"; cin>>w; if(w=='Y'||w=='y') { flag++; s1.fifty2(); } cout<<"n Please give youranswer"; cin>>ans; t=strcmp(ans,rs); if(t==0) { pts=2000; cout<<" YOUR SCORE IS:- "<<pts; f1.open("Game.txt",ios::app); f1<<"n"<<pts; f1.close();
  • 16. cout<<"nPRESSANYKEY FORTHE NEXT QUESTION "; getch(); s1.ques3(); } else { cout<<"aWRONG ANSWER!!!!a"; } } voidquiz::fifty2() { clrscr(); cout<<"nWhohas writtenthe book'DIVINELIFE?"; cout<<"n(c)Swami Sivananda"<<"t(d)Karl Marx"; } //******Question3 voidquiz::ques3() { clrscr(); cout<<"nWhohas writtenthe book'ONELIFE'?"; cout<<"n(a)ChristianBarnard"<<"t(b)Wendell Wilkie"; cout<<"n(c)WilliamWordsworth"<<"t(d)CharlesDarwin"; char rs[]="a"; cout<<"nDO YOU WANT 50/50 LIFELINE(Y/N)"; cin>>w; if(w=='Y'||w=='y') {
  • 17. flag++; s1.fifty3();} cout<<"n Please give youranswer"; cin>>ans; t=strcmp(ans,rs); if(t==0) { pts=3000; cout<<" YOUR SCORE IS:- "<<pts; cout<<"nPRESSANYKEY FORTHE NEXT QUESTION "; f1.open("Game.txt",ios::app); f1<<"n"<<pts; f1.close(); getch(); s1.ques4(); } else { cout<<"aWRONG ANSWER!!!!a"; } } voidquiz::fifty3() { clrscr(); cout<<"nWhohas writtenthe book'ONELIFE'?"; cout<<"n(a)ChristianBarnard"<<"n(c)WilliamWordsworth";
  • 18. } //**********Question 4 voidquiz::ques4() { clrscr(); cout<<"nWhichgame is associate with'YONEXCUP'?"; cout<<"n(a)Golf"<<"t(b)Baseball"; cout<<"n(c)YatchRacing"<<"t(d)Badminton"; char rs[]="d"; if(flag<3) { flag++; cout<<"nDO YOU WANT 50/50 LIFELINE(Y/N)"; cin>>w; if(w=='Y'||w=='y') { flag++; s1.fifty4(); } } cout<<"n Please give youranswer"; cin>>ans; t=strcmp(ans,rs); if(t==0) { pts=5000; cout<<" YOUR SCORE IS :- "<<pts;
  • 19. cout<<"nPRESSANYKEY FORTHE NEXT QUESTION "; f1.open("Game.txt",ios::app); f1<<"n"<<pts; f1.close(); getch(); s1.ques5(); } else { cout<<"aWRONG ANSWER!!!!a"; } } voidquiz::fifty4() { clrscr(); cout<<"nWhichgame is associate with 'YONEXCUP'?"; cout<<"n(a)Golf"<<"t(d)Badminton"; } //Question5 voidquiz::ques5() { clrscr(); cout<<"nWhoinvented'MECHANICALCLOCK'?"; cout<<"n(a)C.Hugyenst(b)SamuelColt"; cout<<"n(c)HsingandLing-Tsant(d)WilhelmRoentgen";
  • 20. char rs[]="c"; if(flag<3) { cout<<"nDO YOU WANT 50/50 LIFELINE(Y/N)"; cin>>w; if(w=='Y'||w=='y') { flag++; s1.fifty5(); } } cout<<"n Please give youranswer"; cin>>ans; t=strcmp(ans,rs); if(t==0) { pts=10000; cout<<" YOUR SCORE IS:- "<<pts; f1.open("Game.txt",ios::app); f1<<"n"<<pts; f1.close(); getch(); clrscr(); cout<<"nttt**********************************************"; cout<<"ntttCONGRATULATIONSYOUHAVECOMPLETED THE FULL SET ";
  • 22.
  • 23. HELP FROM INTERNET INFORMATION FROM BOOKS HELP FROM TEACHERS