project - arpita final
TRANSCRIPT
-
8/7/2019 Project - Arpita FINAL
1/44
-
8/7/2019 Project - Arpita FINAL
2/44
Bonafide certificate
Certified to be the Bonafide record of work done by
_____________ of Std XII, Kola Saraswathi Vaishnav Senior
Secondary School, 41, Barnaby Road, Kilpauk, Chennai-
600010 during the academic year 2009-10.
Date: Subject Teacher
Submitted for All India Senior Secondary Practical
Examination held in COMPUTER SCIENCE at Kola
Saraswathi Vaishnav Senior School, Kilpauk, Chennai-
10.
Date: External Examiner
School Seal
-
8/7/2019 Project - Arpita FINAL
3/44
ACKNOWLEDGEMENT
We would like to express our deep gratitude
to Mrs. B.Sumathi, Our computer science teacher for
helping and guiding us in completing this project
successfully.
We will be failing in our duty, if we dont thank OurPrincipal Mr. S .Athmanathan for his everlasting support
and encouragement in all our action and deeds which has
helped us a long way in finishing this project.
We attribute the success of our project to the combined
effort of the people mentioned above.
-
8/7/2019 Project - Arpita FINAL
4/44
PROJECT DONE :
CLASS :
SUBJECT : Computer Science
PROJECT NAME :
SIGN.OF THE TEACHER
INCHARGE :
SIGN.OF THE EXTERNAL
EXAMINER :
SCHOOL SEAL :
-
8/7/2019 Project - Arpita FINAL
5/44
-
8/7/2019 Project - Arpita FINAL
6/44
The project question paper prepares question paper covering the
following lessons
1. Structure
2. Class & Object3. Constructor & Destructor
4. Function Overloading
5. Inheritance
6. Implementation of data structure
7. Boolean Algebra
8. Files Organization
The program has been stored in the project in the file project &four disk files are used in the program are
1. On1.dat
2. To2.dat
3. Thee3.dat
4. Fiv5.dat
To compile and run the program
1. First go to the directory
2. type TC file
3. Open the file crefile.cpp, press ctrlF9 to compile & run.
4. Open Second file try.cpp, press ctrlF9 to compile & run.
5. Questions are displayed according to the pattern of question
paper.
-
8/7/2019 Project - Arpita FINAL
7/44
SYSTEM ANALYSIS
TOOLS LANGUAGE AND PLATFORM TO BE USED
HARDWARE SPECIFICATION
Memory: 984 KB
Microprocessor:1.2
Hard disk:40 GB
Printer: hp Laser printer
SOFTWARE SPECIFICATION
Platform : C++ with graphics
Front End: C++
Windows XP
M.S Word
-
8/7/2019 Project - Arpita FINAL
8/44
Files required
1.Crefile :
Fields
int no
char ques
2. Try file:
Fields
Int no
Char ques
Class required:
Question
Data and Function Member:
Int no;
Char ques (100)Void getdata ();
Void display();
-
8/7/2019 Project - Arpita FINAL
9/44
Menu1. Creation of files
2. Question selection
3. Display of try files
Project
-
8/7/2019 Project - Arpita FINAL
10/44
Creation of crefile:
The file storing the question is created is created . Thedisk files on1.dat, to2.dat, Thee34.dat & fiv5.dat are
assigned to the file variable . The function getdata () is
used to read the content of files .
Operation:
1. Void one() :
One mark questions are stored.
2. Void two () :
Two mark question are stored.
3. Void three () :Three mark question are stored.
4. Void four () :
Six mark question are stored.
-
8/7/2019 Project - Arpita FINAL
11/44
Question selection :
1. From the disk file on1.dat required
number of mark question are selected.
2. From the disk file to2.dat required
number of two marks question are
selected.
3. From the disk file thee3.dat required
number of three marks question areselected .
4. From the disk file fiv5.dat required
number of five marks question are
selected.
The disk file1.dat is assigned to file variable
Display of try file:
The question papers containing therandomly selection question are displayed.
-
8/7/2019 Project - Arpita FINAL
12/44
-
8/7/2019 Project - Arpita FINAL
13/44
Main menu
a) Crefile
b) Tryfile
Step1: While a then:
Crefile
Step 2: Menu display:
1. Creation
2. Display
Step 3: Enter the choice
Step 4: If choice =1 then
Step 5:
Creation
a) Option is selection for one mark
Read the number of question to be created for one mark
for (i=1 to 20)
Access getdata() function
Write to the object into file
b) Display the information from the file
Access the display ()
Read the object from file
Step 6:
Repeat step 5 for two marks, three marks & six marks
Exit
-
8/7/2019 Project - Arpita FINAL
14/44
Step 7:
While ob
Try file
Step 8:Creation & display of try file
Step 9:
Open on1.dat file 1 one mark
Set r=rand () %21
If (r=0) repeat step 9
Else set a [0]=r, for (I=1 to 5)
Step 10:
Set r=rand (_) %21
If (r=0) repeat step 10
Else if (a[i]=r)repeat step 10
Else set j=j+1
Step 11:
Set a [i]=r, for (I=0 to 5)If (a[i]>a[j])
Set temp=a[i]
a[i]=a[j]
a[j]=temp, set i=0
read file1();
Step 12:
If(a[i]=bank.n)
Set strcpy(paper(==L1),bank.ques)Set i=i+1
Step 13:
-
8/7/2019 Project - Arpita FINAL
15/44
For(i=0 to 11)
Print ++q1
Print paper(i),100:
Step 14:Close File
Step 15:
Repeat step 9th and 13th for two marks, three marks and five
marks.
Step 16:
Compile and run the program.For output.
Step 17:
Exit.
-
8/7/2019 Project - Arpita FINAL
16/44
Start
Input option
-
8/7/2019 Project - Arpita FINAL
17/44
Enter the option
1.Creation and display
2.Selection and display
If Option =
= 0Stop
If Option
= = 1 S
K
X
x
Input numberof questionand marksMark
=0 2
Case1:
one 0 A
Case2:
two 0 B
Case3:
three0 C
Case4:
four0 D
-
8/7/2019 Project - Arpita FINAL
18/44
X
Input marks 2
Yes
For(i=0; i=20;
i++)
Write q getdatafile.write
file.readWhile(file)Write q.getdatafile.write
Read q.displayfile.readfile.closeX
K
X
A
Open a fileFile.open(one.d
ata)
For(i=0; i=20;i++)
Write q getdatafile.write
file.read
While(file)Write q.getdatafile.write
Read q.displayfile.readfile.closeX
K
-
8/7/2019 Project - Arpita FINAL
19/44
-
8/7/2019 Project - Arpita FINAL
20/44
X
B
Open a file
File.open(to2.dat)
For(i
=1;i>n;
cin>>ques;
}
void question::display()
{
puts(ques);
}
int t1=-1,t2=-1,t3=-1;question bank;
char paper[10][100],paper2[5][100],paper3[5]
[100],paper4[5][100];
void heading();
void one();
-
8/7/2019 Project - Arpita FINAL
32/44
void two();
void three();
void five();
question ar1[10],ar2[10],ar3[10];
fstream file1,file2;
int on;
int l1=-1,l2=-1,l3=-1,l4=-1;
void main()
{
heading();
one();two();
three();
five();
}
void heading()
{
clrscr();cout
-
8/7/2019 Project - Arpita FINAL
33/44
cout
-
8/7/2019 Project - Arpita FINAL
34/44
a[j]=temp;
}//end of if
}//end of j loop
}//end of i loop
i=0;
file1.seekg(0);
file1.read((char *)&bank,sizeof(bank));
while(file1)
{
if(a[i]==bank.n)
{
strcpy(paper[++l1],bank.ques);i+=1;
}//End of if
file1.read((char *)& bank, sizeof(bank));
}//end of while
int q1=0;
for(i=1;i
-
8/7/2019 Project - Arpita FINAL
35/44
cout
-
8/7/2019 Project - Arpita FINAL
36/44
int temp=b[i];
b[i]=b[j];
b[j]=temp;
}//end of if
}//end of j loop}//end of i loop
i=0;
file1.seekg(0);
file1.read((char *)&bank,sizeof(bank));
while(file1)
{
if(b[i]==bank.n){
strcpy(paper2[++l2],bank.ques);
i+=1;
}
file1.read((char *)& bank, sizeof(bank));
}
int q2=0;
for(i=1;i
-
8/7/2019 Project - Arpita FINAL
37/44
void three()
{
cout
-
8/7/2019 Project - Arpita FINAL
38/44
if(c[i]>c[j]);
{
int temp=c[i];
c[i]=c[j];
c[j]=temp;}//end of if
}//end of j loop
}//end of i loop
i=0;
file1.seekg(0);
file1.read((char *)&bank,sizeof(bank));
while(file1){
if(c[i]==bank.n)
{
strcpy(paper3[++l3],bank.ques);
i+=1;
}
file1.read((char *)& bank, sizeof(bank));
}int q3=0;
for(i=1;i
-
8/7/2019 Project - Arpita FINAL
39/44
void five()
{
cout
-
8/7/2019 Project - Arpita FINAL
40/44
for(int j=i+1;jd[j]);
{
int temp=d[i];d[i]=d[j];
d[j]=temp;
}//end of if
}//end of j loop
}//end of i loop
i=0;
file1.seekg(0);file1.read((char *)&bank,sizeof(bank));
while(file1)
{
if(d[i]==bank.n)
{
strcpy(paper4[++l4],bank.ques);
i+=1;
}file1.read((char *)& bank, sizeof(bank));
}
int q4=0;
for(i=1;i
-
8/7/2019 Project - Arpita FINAL
41/44
}
KOLA SARASWATHI VAISHNAV SENIOR SECONDARY SCHOOL
I UNIT TEST
X11 STD 35 MARKS
7.1.2011 1 HOUR
ANSWER THE FOLLOWING ONE MARK QUESTIONS (1*4=4)
-
8/7/2019 Project - Arpita FINAL
42/44
1.Name the header files that shall be needed for the following code:
void main()
{
char sring[]=peace;
count
-
8/7/2019 Project - Arpita FINAL
43/44
(b)GSM and CDMA
ANSWER THE FOLLOWING SIX MARKS QUESTION (1*6=6)
1.(a) State De Morgans Laws and verify it using truth table. 2
(b) Write the Dual of the Boolean Expression (B+C).A 1
(c) What is the purpose of using repeater in context of networking. 1
(d) Write one advantage and one disadvantage of the following topologies: 2
(i) BUS topologies (ii) STAR topologies
-
8/7/2019 Project - Arpita FINAL
44/44
Computer Science with C++ by Sumitra Arora
Object Oriented Programming in C++ by Robert Lafore