CIS 170C iLab 1 of 7 Getting Started (100 % Correct) CIS 170C iLab 1 of 7 Getting Started (100 % Correc | Page 7
Pseudo Code:
1. Declare variables
2. Accept Input - weeklySales
3. Calculate Gross Pay = Weekly Sales * .07
4. Calculate Federal Tax = Gross Pay * .18
5. Calculate Social Security = Gross Pay * .06
6. Calculate Retirement = Gross Pay * .1
7. Calculate Total Deductions = Federal Tax + Social Security + Retirement
8. Calculate Total Take Home Pay = Gross Pay - Total Deductions
9. Display the following on separate lines and format variables with $ and decimal.
a. Total Sales Amount:
b. Gross Pay (.07):
c. Federal Tax paid (.18):
d. Social Security paid (.06): value of social security
e. Retirement contribution (.1): value of retirement
f. Total Deductions:
g. Take Home Pay:
value of weekly sales
value of gross pay
value of federal tax
value of total deductions
value of take home pay
Note: Use SetPrecisions(2) to format the output (see page 98 of the text). The statements
should look something like the following:
//include the iomanip header file at the top of the file