I just want the program to show me the quality points but when I compile it it says "[Linker Error] undefined reference to 'getGradeInfo(int&, char&, int&, char&)'Id returned 1 exit status." I have no idea what this means or why I'm getting it. This is my code.
#include <iostream>
#include <iomanip>
using namespace std;
void getGradeInfo(int& c1credits, int& c1grade, int& c2credits, int& c2grade)
{
cout<<"Enter the # of credits and your grade for class #1 "<<endl;
cin>>c1credits,c1grade;
cout<<"Enter the # of credits and your grade for class #2 "<<endl;
cin>>c2credits,c2grade;
}
int getQualityPoints(int c1credits,char& c1grade,char& c2grade,int c2credits)
{
void getGradeInfo(int& c1credits, int& c1grade, int& c2credits, int& c2grade)
{
cout<<"Enter the # of credits and your grade for class #1 "<<endl;
cin>>c1credits,c1grade;
cout<<"Enter the # of credits and your grade for class #2 "<<endl;
cin>>c2credits,c2grade;
}
check out cin's again... cin >> some_variable >> some_variable2;
Your formal paramter lists are different.
In the future, be sure to post your code in code tags. That way, your code will appear like it does in this post.