ALright so basically your suppose to tell the program the length and width of room and cost per sq foot. And the program should calculate the total including labor and tax cost. The labor and tax cost are both constant. Labor = 0.35 Tax=0.05.
#include <iostream>
#include <iomanip>
using namespace std;
void get_data(int & length,int& width,float costpersqfoot);
float InstalledPrice(int length,int width,float costpersqfoot);
float totalprice(float installion);
void printdata(int length,int width,float price);
const float LABOR_COST=0.35;
const float TAX_RATE=0.05;
int main ()
{
int length,width;
int count;
cout << " Enter number of mesurements to input";
cin >> count;
for (int i=1; i <=count; i++)
{
get_data (length,width);
float Installedprice = length * width * float costpersqfoot + LABOR_COST;
cout << " Your installed price is" <<
setprecision(2) << length * width * float costpersqfoot + LABOR_COST + TAX_RATE << endl;
cout << " Your total price is" <<
Oh sorry I'm just wondering if u could tell me what I did wrong cause when I try to compile it doesn't come out right I think I'm missing something in my code so if u could plaza help I would appreciate it.
Your get_data function has 3 formal parameters, and you only put two where you actually code it. You declared a float "costpersqfoot" without giving it and kind of operations.
float costpersqfoot = blah blah blah
then take out the return length * width * float costpersqfoot + LABOR_COST;
Im sorry I'm new in programming what do I put float costpersqfoot=. because the user is suppose to enter the costpersqfoot lenght and the width and then the program just adds the tax and labor cost.