functions

Jan 17, 2013 at 7:53pm
this is my question. "You own a small restaurant chain and continually have errors in the calculation the customer’s bill. Additionally the wait staff is always complaining that they are being shorted on their tips. Your customer wants a program that will calculate the sales tax and then provide an itemized total bill. Sales taxes range from 4.3% to 11%. Also calculate and display recommended tips for that total bill for the recommended tips of: 15%, 18% and 20%."

This is what I have so far:

double valuepassingexample (int a, float b=2.2 double c=3.003, float d=43.987);

int main (void)
{
int a;
float b, d;
double answer, c;

cout << please input the interger a ="; cin >> a; cout << endl << "\n"
cout << "a=" << a << " b=" << b << " c=" << c << endl;

system ("pause");

answer
}

what am I doing wrong
Jan 17, 2013 at 8:02pm
You code contains syntaxical errors, using of uninitialized variables and has no the definition of function valuepassingexample.
Jan 17, 2013 at 8:07pm
how should I fix it
Jan 17, 2013 at 8:18pm
Fix the syntax errors, initialize variables before you use them, and define valuepassingexample().
Jan 17, 2013 at 8:30pm
ok after I do that should I submit it to my professor.
Thanks
Topic archived. No new replies allowed.