Computer Science Project File
Computer Science Project File
SCIENCE
PROJECT FILE
ON
COACHING CLASS
DATA
MANAGEMENT
TABLE OF CONTENTS
Certificate
Acknowledgement
Coding
Limitations
Requirements
Bibliography
Acknowledgement
I would like to express a deep sense of thanks
& gratitude to my project guide Mrs. Meena
Gupta Mam for guiding me immensely
through the course of the project. She always
evinced keen interest in my work. Her
constructive advice & constant motivation
have been responsible for the successful
completion of this project. My sincere thanks
goes to Shri M.L Aggarwal, our principal sir,
for his co-ordination in extending every
possible support for the completion of this
project. I also thanks to my parents for their
motivation & support, I must thanks to my
classmates for their timely help & support for
compilation of this project Last but not the
least, I would like to thank all those who had
helped directly or indirectly towards the
completion of this project.
-ABHISHEK
Certificate
This is to certify that ABHISHEK of class
XII-A has prepared the report on the project
entitled
Coaching
Classes
Data
Management. The report is the result of his
efforts & endeavors. The report is found
worthy of acceptance as final project report for
the subject Computer Science of class XII. He
has prepared the report under my guidance.
( Mrs.
Meena Gupta )
PGT (Computer Science)
Kendriya Vidyalaya NFC
Certificate
entitled Coaching
Classes Data Management, Submitted by
ABHISHEK of Class XII A for the CBSE
Senior Secondary Examination class XII of
Computer Science at Kendriya Vidyalaya
Vigyan Vihar has been examined.
The
project
report
Signature Of Examiner
CODING
#include<fstream.h>
#include<conio.h>
#include<ctype.h>
#include<stdio.h>
#include<string.h>
#include<process.h>
class data
{char name[30];
long int enrolmntid;
int M1M;
int M2M;
int M3M;
int total_mark;
public:
data()
{enrolmntid=0;
strcpy(name,"");
M1M=0;
M2M=0;
M3M=0;
total_mark=0;
}
void enter_name_marks()
{cout<<"\nEnter Student
Enrollment ID (Integral) : ";
cin>>enrolmntid;
cout<<"\nEnter Student Name :
";
gets(name);
cout<<"\nJEE MOCK MAIN 1
Marks(s) Out Of 360 : ";
cin>>M1M;
cout<<"\nJEE MOCK MAIN 2
Marks(s) Out Of 360 : ";
cin>>M2M;
cout<<"\nJEE MOCK MAIN 3
Marks(s) Out Of 360 : ";
cin>>M3M;
total_marks();
}
void show_record()
{cout<<"\nStudent Enrollment
ID
:"<<enrolmntid;
cout<<"\nStudent Name
: "<<name;
cout<<"\nJEE MOCK MAIN 1
Mark(s)
: "<<M1M;
cout<<"\nJEE MOCK MAIN 2
Mark(s)
: "<<M2M;
cout<<"\nJEE MOCK MAIN 3
Mark(s)
: "<<M3M;
cout<<"\nTotal Mark(s)
: "<<total_mark;
}
void total_marks()
{total_mark=M1M+M2M+M3M;
}
int getstudentid()
{return enrolmntid;
}
int gettotalmarks()
{return total_mark;
}
char* get_name()
{return name;
}
void modify_data()
{cout<<"\n::::::::Enter New Data
For Modification :::::::: ";
cout<<"\nEnter JEE MOCK MAIN
1 Mark(s) Out of 360: ";
cin>>M1M;
cout<<"\nEnter JEE MOCK MAIN
2 Mark(s) Out Of 360: ";
cin>>M2M;
cout<<"\nEnter JEE MOCK MAIN
3 Mark(s) out Of 360: ";
cin>>M3M;
total_marks();
} };
data d;
fstream file;
fstream file1;
void highest()
{ file.open("record.dat",ios::in|
ios::binary);
int post=0,mark=0;
float tm=0;
file.read((char*)&d,sizeof(d));
while(file)
{mark=d.gettotalmarks();
if(mark>tm)
{post=file.tellg();
tm=mark;
}
file.read((char*)&d,sizeof(d));
}file.close();
file.open("record.dat",ios::in|
ios::binary);
file.seekg(post-sizeof(d));
file.read((char*)&d,sizeof(d));
cout<<"\n::::::::::Highest Marks
Getter Student Data::::::::::";
cout<<"\nHighest Mark(s) Getter
Enrollment ID
:
"<<d.getstudentid();
cout<<"\nHighest Mark(s) Getter
Student Is : "<<d.get_name();
cout<<"\nStudent Total Mark(s)
are
: "<<tm;
float per;
per=(tm/108)*10.0;
cout<<"\n\n Student
Percentage Is
: "<<per;
file.close();
}
void insert()
{int i,no;
file.open("record.dat",ios::in|
ios::app|ios::binary);
cout<<"\n ::::::::Entry Of New
Student(s)::::::::
";
cout<<"\nHow Many Records Of
New Student(s) You Want To
Enter : ";
cin>>no;
for(i=1;i<=no;i++)
{d.enter_name_marks();
//insert records
file.write((char*)&d,sizeof(d));
}file.close();
}
void display()
{file.open("record.dat",ios::in|
ios::binary);
cout<<"\n|||||||||||||||||||||| Entered
Record(s) ||||||||||||||||||||||||";
file.read((char*)&d,sizeof(d));
while(file)
{d.show_record();
file.read((char*)&d,sizeof(d));
}file.close();
}
void search()
{int p,r,srch=0;
file.open("record.dat",ios::in|
ios::binary);
cout<<"\nEnter The Student
Enrollment ID To See His
Record : ";
cin>>r;
file.seekg(0);
file.read((char*)&d,sizeof(d));
while(file)
{p=d.getstudentid();
if(r==p)
{d.show_record();
srch=1;
break;
}
else
{ file.read((char*)&d,sizeof(d));
}
}file.close();
if(srch==0)
{cout<<"\nThere Is No Student
Which Have This Enrollment
ID .";
}
}
void modify()
{int posi=0,got=0,dmd=0;
cout<<"\nEnter the playercode
whose record to be modified : ";
cin>>dmd;
int ifdata=1;
file.open("record.dat",ios::in|
ios::out|ios::binary);
posi=file.tellg();
while(file)
{ file.read((char*)&d,sizeof(d));
got=d.getstudentid();
if(dmd==got)
{file.seekg(posi);
d.modify_data();
ifdata=2;
file.write((char*)&d,sizeof(d));
break;
}
posi=file.tellg();
}
file.close();
if(ifdata==1)
{cout<<"\n
Data Not
Available For Modification
}
}
";
void delete_record()
{int remove_record=0,id_get=0;
cout<<"\n Enter The Student's
Enrollment ID Whose Record To
Be Deleated : ";
cin>>remove_record;
file.open("record.dat",ios::in|
ios::out|ios::binary);
file1.open("tempo.dat",ios::in|
ios::out|ios::binary);
file.seekg(0);
while(file)
{file.read((char*)&d,sizeof(d));
id_get=d.getstudentid();
if(remove_record==id_get)
{cout<<" ";
}
else
{ file1.write((char*)&d,sizeof(d))
;
}
}file.close();
file1.close();
remove("record.dat");
rename("tempo.dat","record.dat
");
}
void main()
{clrscr();
int choice;
char ans='n';
do
{cout<<"\n=*=*=*=*=*=*=*=*=*
ENROLLED STUDENTS IN A
COACHING- ABHISHEK 12-A 08
*=*=*=*=*=*=*=*=*=*";
cout<<"\n (1) INSERT RECORD \n
(2) DISPLAY RCEORDS \n (3)
SEARCH RECORD \n (4) MODIFY
RECORD \n (5)
HIGHEST MARKS \n (6) DELETE
PREVIOUS ENTERED RECORD \n
(7) EXIT ";
REQUIREMENTS
HARDWARE REQUIRED
Printer, to print the required documents
of the project
Compact Drive
Processor : Pentium III
Ram : 64 MB
Harddisk : 20 Gb.
SOFTWARE REQUIRED
BIBLIOGRAPHY
1)
http://www.google.com/
2)
http://en.wikipedia.org
www.bOtskOOL.com