This is a weekly pay calculating and writing program


Major concepts: ? LOOP, IF, FUNCTIONS, POINTERS, ALIGNED OUTPUT, and VERIFY DATA
This is a WEEKLY pay calculating and writing program. The program accepts input from the user and generates pay stub forms for each employee like the sample below. The forms MUST line up EXACTLY as in the following example.
Special note:
You will have to count the spacing to get it to look correct. The first 2 lines of numbers you see are NOT part of the output. Also the first 2 numbers on each line on the left side are row or line numbers and are also NOT part of the output. These numbers are to show you how to align the output. In the form below you will see 2 versions of line 6. This is explained in requirement 1 below.
xx0000000001111111111222222222233333333334444444444555555
xx1234567890123456789012345678901234567890123456789012345
01Yourname Payroll Systems
02102 Orfus Road, Downsview ON
03
04Employee Number: 999 For Week Ending: YYYYMMDD
05
06Salary Paid :999999.99
06Hourly Rate: 99.99 Hours Worked: 99.99
07
08GROSS PAY: 9999.99
09
10DEDUCTIONS:
11Long Term Benefits: 99.99
12Employment Insurance: 999.99 
13Canada Pension Plan: 9999.99
14Federal Tax: 9999.99 
15
16TOTAL DEDUCTIONS: 9999.99
17
18NET PAY: 9999.99
Requirements for the program
1 Either the "Salary Paid:" line (06), or the "Hourly rate:" and "Hours worked:" line (06), will appear on the form.
Not both. The one that appears will depend on the type of employee. The above sample shows both lines, but
you should ONLY print the correct line.
2 Overtime rate. For hourly paid employees, the rate of pay for hours in excess of 44 is at 1.5 times the
normal rate of pay.
3 Long-term benefits (LTB) are charged at $2 per every full $100 of gross weekly earnings to a maximum
LTB payment of $100 per week. An example of a gross weekly pay of $163 will result in a $2 LTB deduction,
as there is only one full $100 amount. Make sure you understand the requirement.4 Employment Insurance (EI) is 1.4% of gross pay to a maximum of $11.80 per week. Everyone pays it.
5 Canada Pension Plan is paid by everyone and is 1.6% of gross pay on the first $700 of earnings in a week. 
6 Federal taxes are paid by everyone and is calculated based on what a person would earn for a full year.
The rates are: 16% on the first $20,000 earned annually
23% on the next $20,000 earned annually
29% on the remainder earned annually
As this is a weekly pay, you will have to assume hourly paid people will make the same amount every week for
52 weeks per year to calculate their annual salary.
7 Provincial Tax which is collected along with the Federal Tax, is an additional 47% of the Federal tax
collected. The 2 amounts, Provincial and Federal tax, are shown as the one figure Federal Tax on the form.
8 The program must LOOP until the user decides they have done enough. Use a few n to separate the
question and the inputs from the output for readability.
9. The program must have these modules/functions as a minimum and demonstrate pointers
(i) Controlling the decision to loop ie. The question that asks them if they want to input data for another
employee. This answer must be a character ('Y' or 'y') and not 1 for yes etc 
(ii) The inputs 
(iii) The 4 deductions - long-term benefit calculation (LTB),
(iv) - Employment insurance (EI),
(v) - Canada pension plan (CPP),
(vi) - Federal and Provincial tax (FT and PT).
(vii) The output form
This program requires a minimum 7 modules or functions and of course the main () function.
10. No global variables allowed. 
11. Deductions will occur for names that are not meaningful, improper indents or alignment, lack of blank
lines, missing program documentation at the beginning and clearly distinguishing the end of main and the
beginning of the functions and for other factors that make the program poor to read and understand. This
MUST be very easy to read and understand...quickly.
You should test your program with a greater variety of test data than shown below, but for the purposes of this
assignment you are to turn in the output from using at least the following test data. None of these values are
hard coded into the program. This is test data, the program should work with real data, so do not assume
things like, there are only 6 employees or that the salary employees have employee numbers greater than
400.
Empno Hourly Hours Rate
Salary Worked
111 h 35 $ 15.75 per hour
222 h 44 $ 40.00 per hour
333 s $752,000 per year
444 h 50 $ 85.00 per hour
555 s $125,000 per year
666 s $ 40,000 per year
Submission:
See your teacher's assignment submission requirements.
Note the user inputs h or s and not
1 or 2 

Request for Solution File

Ask an Expert for Answer!!
Programming Languages: This is a weekly pay calculating and writing program
Reference No:- TGS0134329

Expected delivery within 24 Hours