Professional Documents
Culture Documents
h>
class student {
int rno;
char sname[21];
float eng,maths,phy,chem,bio;
float total;
float ctotal()
void showdata();
};
void student::takedata()
cin.getline(sname,21);
cin>>rno;
cout<<"\n Marks\n";
cout<<"English:";
cin>>eng;
cout<<"Maths:";
cin>>maths;
cout<<"Physics:";
cin>>phy;
cout<<"Chemistry:";
cin>>chem;
cout<<"Biology:";
cin>>bio;
cout<<endl;
total=ctotal();