Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

my program isn't running; please help identify errors : file:main.cpp #include stdafx.h #include #include studentType.h using std::cout; using std::endl; void testStudentType() { { cout <

my program isn't running; please help identify errors :

file:main.cpp

#include "stdafx.h"

#include

#include "studentType.h"

using std::cout;

using std::endl;

void testStudentType()

{

{

cout << "Enter a student's first name:";

cin >> fName;

cout << "Enter a student's last name:";

cin >> lName;

cout << "Enter a student's test score:";

cin >> tScore;

cout << "Enter a student's programing score:";

cin >> pScore;

cout << "Enter a students gpa:";

cin >> gpa;

studentType st(fName, lName, tScore, Pscore, gpa);

int main()

{

testStudentType();

system("pause");

return 0;

}

file studentType.cpp

#include "stdafx.h"

#include "studentType.h"

studentType::studentType(string newFirstName, stringnewLastName, int newTestScore, int newProgrammingScore, double newGPA)

{

}

string studentType::getFirstName()

{

return firstName;

}

string studentType::getLastName()

{

return lastName;

}

char studentType::getGrade()

{

return Grade;

}

int studentType::getTestScore()

{

return testScore;

}

int studentType::getProgrammingScore()

{

return programmingScore;

}

double studentType::getGPA()

{

return gpa;

}

void studentType::setFirstName(string newFirstName)

{

firstName = newFirstName;

}

void studentType::setLastName(string newLastName)

{

lastname = newLastName;

}

void studentType::setTestScore(int newTestScore)

{

testScore = newTestScore;

}

void studentType::setProgrammingScore(int newProgrammingScore)

{

programmingScore = newProgrammingScore;

}

void studentType::setGPA(double newGPA)

{

gpa = newGPA;

}

file : studentType.h

#pragma once

#include

using std::string;

class studentType

{

private:

string firstName;

string lastName;

char Grade;

int testScore;

int programmingScore;

double GPA;

public:

studentType(string = "", string = "", int = 0, int = 0, double = 0.0);

string getFirstName();

string getLastName

char getGrade();

int getTestScore();

int getProgrammingScore();

double getGPA();

void setFirstName(string);

void setLastName(string);

void setTestScore(int);

void setProgrammingScore(int);

void setGPA(double);

};

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Financial management theory and practice

Authors: Eugene F. Brigham and Michael C. Ehrhardt

12th Edition

978-0030243998, 30243998, 324422695, 978-0324422696

Students also viewed these Programming questions

Question

Evaluate the quality of secondary data sources.

Answered: 1 week ago

Question

Blood enters into the heart because muscle of.......?

Answered: 1 week ago

Question

Cardiac output is determined by.......?

Answered: 1 week ago

Question

In human being the duration of cardiac cycle is........?

Answered: 1 week ago