Jul 27, 2011 at 5:29pm UTC
The cout statements work to enter the information but the actual answer never returns. Am I missing a cout mabye. You help is so greatly appreciated.
#include <iostream>
#include <string>
using namespace std;
int multIt(int x, int y);
int pWidth;
int pLength;
int main()
{
cout << "Enter the propWidth: ";
cin >> pWidth;
cout << endl;
cout << "Enter the property length: ";
cin >> pLength;
cout << endl;
multIt(pLength, 2); // + multIt(pWidth, 2);
system("pause");
return 0;
}
int multIt(int x, int y)
{
return x * y;
}
Jul 27, 2011 at 6:46pm UTC
Yes, you need to have a statement to display the result of the multIt() function. BTW, why are you hard-coding 2 instead of passing pWidth to multIt()?