error LNK2019: unresolved external symbol "double __cdecl getArea(double,double)" (?getArea@@YANNN@Z) referenced in function _main
error LNK1120: 1 unresolved externals
if you can please help me because this isn't the first program that I've run into a problem like this and I can't figure out what is wrong.
usually, I write my programs from scratch but this challenged required a pre-written code and I ahad to finish it but i keep getting thse two error codes please help me.
/*
Francisco Diaz
April 20, 2016
CIS-17A: C++ Programming
Chapter 6, Programming Challenge 2
*/
#include <iostream>
using namespace std;
// Write the prototypes for the getLength,
// getWidth, getArea, and displayData
// functions here.
double getLength();
double getWidth();
double getArea(double , double );
void displayData(double,double,double);
int main()
{
double length, // The rectangle's length
width, // The rectangle's width
area; // The rectangle's area
// Get the rectangle's length.
length = getLength();
// Get the rectangle's width.
width = getWidth();
// Get the rectangle's area.
area = getArea(length,width);
// Display the rectangle's data.
displayData(length, width, area);
system("PAUSE");
}
//***************************************************
// You must write the getLength, getWidth, getArea, *
// and displayData functions. *
//***************************************************
double getLength()
{
double length;
cout<<"What is the length of the rectangle: ";
cin>>length;
return length;
}
double getWidth()
{
double width;
cout<<"What is the width of the rectangle: ";
cin>>width;
return width;
}