yourmaster10
Active Member
- Joined
- Jul 2, 2007
- Sythe Gold
- 0
- Messages
- 199
I'm trying to make a program to calculate taxes, and i'm getting a lot of output errors, but, i haven't changed my style of writing, nor have i changed anything else, any help? I'll copy the code to see if anyone can help.
I'm getting syntax errors on lines 16(2 of them), 33, and 34(2 here as well)
I'm getting syntax errors on lines 16(2 of them), 33, and 34(2 here as well)
Code:
#include <iostream>
#include <iomanip>
#include <math.h>
using namespace std
;void main()
{
double grossIncome;
double hoursWorked;
double netIncome;
double incomeTax;
double provincialTax;
double pension;
double EI;
double income;
cout<< "Welcome"<<endl"This program will help you with your taxes, and will figure your net income."<<endl<endl;
cout<< "I will take your hourly salary and your hours worked in, and deduct all taxes"<<endl<<endl;
cout<< "then I will display your net income."<<endl<<endl;
cout<< "Please input your hourly salary";
cin>>income;
cout<<endl<<endl<<"Please input how many hours you worked this week"<<endl;
cin>>hoursWorked;
if (hoursWorked>40)
netIncome = (40 * income) + ((hoursWorked - 40)*(income * 1.5));
else netIncome = hoursWorked * income;
incomeTax = netIncome * .17;
provincialTax = netIncome * .07;
pension = netIncome * .039;
EI = netIncome * .0255;
grossIncome = netIncome - incomeTax - provincialTax - pension - EI;
cout<<endl<<"Your gross income is "<<grossIncome<<"! Wow, the taxman bites eh?"<<endl;
system ("pause");
}




