find and fix all the errors so the code can run #ifndef Student.h #define Student.h class CStudent{ private: char Student_name[50]; int Student_id; char Student_email_username[10]; char...


find and fix all the errors so the code can run


#ifndef Student.h
#define Student.h


class CStudent{
private:
char Student_name[50];
int Student_id;
char Student_email_username[10];
char Student_major[10];
float Student_grades[5];
float Student_score;
char Student_email_password[10];


public:
CStudent();


char *get_Student_name();
int get_student_id();
char *get_Student_email_username();
char *get_Student_major();
float *get_Student_grades();
float get_Student_score();
char *get_Student_email_password();




//set methods
void set_Student_name(char *name);
void set_student_id(int id);
void set_Student_email_username(char *username);
void set_Student_major(char *major);
void set_Student_grades(float *grades);
void set_Student_score(float score);
void set_Student_email_password(char *password);


};


#endif


#include "Student.h"
#include


CStudent::CStudent()
{
Student_name[50]={};
Student_id=0;
Student_email_username[10]={};
Student_major[10]={};
Student_grades[5]=0;
Student_score=0;
Student_email_password[10]={};
}


char CStudent:: *get_Student_name()
{
return Student_name;
}
CStudent::~CStudent(){delete s[];}
int CStudent:: get_Student_id()
{
return Student_id;
}
char CStudent:: *get_Student_email_username()
{
return Student_email_username;
}


char CStudent:: *get_Student_major()
{
return Student_major;
}


float CStudent:: *get_Student_grades()
{
return Student_grades;
}


float CStudent:: get_Student_score()
{
return Student_score;
}
char CStudent:: *get_Student_email_password()
{
return Student_email_password;
}



void CStudent:: set_Student_name(char *name)
{
Student_name=name;
}
void CStudent:: set_Student_id(int id)
{
Student_id=id;
}
void CStudent:: set_Student_email_username(char *username)
{
Student_email_username=username;
}
void CStudent:: set_Student_major(char *major)
{
Student_major=major;


}
void CStudent:: set_Student_grades(float *grades)
{
Student_grades=grades;
}
void CStudent:: set_Student_score(float score)
{
Student_score=score;
}
void CStudent:: set_Student_email_password(char *password)
{
Student_email_password=password;
}
void CStudent:: getStudentInfo(){
CStudent (char Student_name[50], int Student_id, char Student_email_username[10], char Student_major[10],
float Student_grades[5], float Student_score, char Student_email_password[10])
{


cout<"the student's=""><><>


cout<"the student's=""><><>
cout<"the student's="" email=""><><>
cout<"the student's=""><><>
cout<"the student's=""><><>
cout<"the student's=""><><>
cout<"the student's="" email=""><><>
}
void calculateGPA(char Student_name[50], int Student_id, char Student_email_username[10], char Student_major[10],
float Student_grades[5], float Student_score, char Student_email_password[10])
{
int sum;
cout<"enter the="" no="" of="">
cin>>n;
for(int j=0;j<>
{
for(int i=0;i<>
{
sum=sum+grades[i];
}
student_score=sum/100;
}
}


void registerStudent()
{


char Student_name[50];


cout<"please enter="" student's="">
getline(Student_name, 50);


int Student_id;


cout<"please enter="" student's="">
cin>>Student_id;


char Student_email_username[10];
// prompt for the student's Email
cout<"please enter="" student's="" email="">
getline(Student_email_username, 10);


char Student_major[10];
cout<"please enter="" student's="">
getline(Student_major, 10);




float Student_grades[5];


for (int i=1; i<=5;>
{
cout<"please enter="" student's="" grades="" in="" subject="">cin>>Student_grades[i];
}



float Student_score;
cout<"please enter="" student's="">
cin>>Student_score;


char Student_email_password[10];
cout<"please enter="" student's="" email="">
getline(Student_email_password, 10);


}




Jun 07, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here