Already have an account? Get multiple benefits of using own account!
Login in your account..!
Remember me
Don't have an account? Create your account in less than a minutes,
Forgot password? how can I recover my password now!
Enter right registered email to receive password!
Program is to define a class as student:
Program is to define a class as student and display the records specific depending upon the number
class student
{
private:
int roll,i;
char name[20],grade;
float per;
int marks[5],total;
int calculate()
per=total/5;
return per;
}
public:
student()// constructor assigning initial values
total=0;
void input();
void disp();
// void disp_spe();
};
void student::input()
cout<<" enter your name "< gets(name); cout<<" enter your roll no. "< cin>>roll; cout<<" enter the marks of five subjects "< for (i=0;i<=4;i++) { cin>>marks[i]; total=total+marks[i]; } } void student::disp() { clrscr(); cout<<" R E P O R T C A R D "<<"\n\n"; cout<<" The name is : "< cout<<" The marks of all subjects is :"<<"\n"; for (i=0;i<=4;i++) { cout< } calculate(); cout<<" The percentage is :"< if(per>=85) cout<<" The grade is : A"; else if(per>40) cout<<" the grade is : D"; else cout<<" The grade is : B"; } void student::disp_spe() { int rollno; cout<<" enter the students roll no. you want report card " cin>>rollno; if( void main() { clrscr(); student *data; data=new student; data->input(); data->disp(); data->disp_spe(); delete data; }
gets(name);
cout<<" enter your roll no. "< cin>>roll; cout<<" enter the marks of five subjects "< for (i=0;i<=4;i++) { cin>>marks[i]; total=total+marks[i]; } } void student::disp() { clrscr(); cout<<" R E P O R T C A R D "<<"\n\n"; cout<<" The name is : "< cout<<" The marks of all subjects is :"<<"\n"; for (i=0;i<=4;i++) { cout< } calculate(); cout<<" The percentage is :"< if(per>=85) cout<<" The grade is : A"; else if(per>40) cout<<" the grade is : D"; else cout<<" The grade is : B"; } void student::disp_spe() { int rollno; cout<<" enter the students roll no. you want report card " cin>>rollno; if( void main() { clrscr(); student *data; data=new student; data->input(); data->disp(); data->disp_spe(); delete data; }
cin>>roll;
cout<<" enter the marks of five subjects "< for (i=0;i<=4;i++) { cin>>marks[i]; total=total+marks[i]; } } void student::disp() { clrscr(); cout<<" R E P O R T C A R D "<<"\n\n"; cout<<" The name is : "< cout<<" The marks of all subjects is :"<<"\n"; for (i=0;i<=4;i++) { cout< } calculate(); cout<<" The percentage is :"< if(per>=85) cout<<" The grade is : A"; else if(per>40) cout<<" the grade is : D"; else cout<<" The grade is : B"; } void student::disp_spe() { int rollno; cout<<" enter the students roll no. you want report card " cin>>rollno; if( void main() { clrscr(); student *data; data=new student; data->input(); data->disp(); data->disp_spe(); delete data; }
for (i=0;i<=4;i++)
cin>>marks[i];
total=total+marks[i];
void student::disp()
clrscr();
cout<<" R E P O R T C A R D "<<"\n\n";
cout<<" The name is : "< cout<<" The marks of all subjects is :"<<"\n"; for (i=0;i<=4;i++) { cout< } calculate(); cout<<" The percentage is :"< if(per>=85) cout<<" The grade is : A"; else if(per>40) cout<<" the grade is : D"; else cout<<" The grade is : B"; } void student::disp_spe() { int rollno; cout<<" enter the students roll no. you want report card " cin>>rollno; if( void main() { clrscr(); student *data; data=new student; data->input(); data->disp(); data->disp_spe(); delete data; }
cout<<" The marks of all subjects is :"<<"\n";
cout< } calculate(); cout<<" The percentage is :"< if(per>=85) cout<<" The grade is : A"; else if(per>40) cout<<" the grade is : D"; else cout<<" The grade is : B"; } void student::disp_spe() { int rollno; cout<<" enter the students roll no. you want report card " cin>>rollno; if( void main() { clrscr(); student *data; data=new student; data->input(); data->disp(); data->disp_spe(); delete data; }
calculate();
cout<<" The percentage is :"< if(per>=85) cout<<" The grade is : A"; else if(per>40) cout<<" the grade is : D"; else cout<<" The grade is : B"; } void student::disp_spe() { int rollno; cout<<" enter the students roll no. you want report card " cin>>rollno; if( void main() { clrscr(); student *data; data=new student; data->input(); data->disp(); data->disp_spe(); delete data; }
if(per>=85)
cout<<" The grade is : A";
else if(per>40)
cout<<" the grade is : D";
else
cout<<" The grade is : B";
void student::disp_spe()
int rollno;
cout<<" enter the students roll no. you want report card "
cin>>rollno;
if(
void main()
student *data;
data=new student;
data->input();
data->disp();
data->disp_spe();
delete data;
It is a class defined in the scope of a function _ any function, whether a member functions or a free function. For instance: // Example : Local class // int f() { c
Newton's method for cube roots is based on the fact that if y is an approximation to the cube root of x, then a better approximation is given by the value: (x/y 2 +2y)/3 (a)
superposition of waves
Programming Assignment # 1 C and UNIX The purpose of this assignment is to get you more familiar with Unix/Linux and those constructs of C that are not part of C++. Write a C
You are required to write a stand-alone DSP application in the C programming language. The overall objective of this application is to convert a signal from the time domain to t
Define Bitwise-Shift Operators? The shift operators perform suitable shift by operator on the right to the operator on the left. The right operator should be positive. The va
Program of function overloading: class vector{ private : int v[3]; public: /*friend istream &
Problem : (a) Stacks can be implemented using arrays. Write down the following C or C++ function to (i) create a stack (ii) add an element to a stack (push). (b) Expl
Need algorithm for c programe #Minimum 100 words accepted#
Your task is to create a programming system for a ferry. The ferry transports passengers and vehicles (cars, busses, lorries and bicycles). The ferry has space for 200 passengers a
Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!
whatsapp: +1-415-670-9521
Phone: +1-415-670-9521
Email: [email protected]
All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd