Question: Write in C + + . Please be pacific in creating a new code. Please add a data dictionary. Create a file ( datafile )
Write in C Please be pacific in creating a new code. Please add a data dictionary. Create a file datafile named csciout that has your full name, Course name and Date on the first three lines. Then write a program using the instructions below that will open the output file in append mode and write your output to this file.
Program Instructions:
Write a C program that will read records into an array from a data file. Each record should contain an employee ID hours worked and pay rate. You should calculate a total pay and then append the data to the csciout output file. Again, before execution of your program, create the csciout file and include in it your name, course name and date each on a new line.
NOTE: You should submit four different files hout, txt and cpp
The Record written should consist of Employee ID hours worked, pay rate and total pay.
DescriptionDataType Variables
Employee IDsof INT employeesjd
Hours Workedof DOUBLEhrworkedjd
Pay Rateof DOUBLEpayratejd
Total Payof Double totalpay
Excluding the main function, your program should have three additional functions that will get the employee id hours worked, and payrate; another to calculate the total pay; and another to write your output to the output file. Total pay should be calculated based on a hour work week. Calculate the employee pay giving time and one half for overtime hours.
Note: jd represents the initials of the programmer. Your function names should be named by replacing the initials jd with your first and last initials.
Read Input FileCalculate Pay Output Results
Name of function getjdcalcjdprtjd
Properties of function Called from main Called from main Called from main
Should pass
Should pass Should pass hoursemployee id hours
Definition of Function employee id hours worked and payrate worked and payrate
worked, payrate and calculate total pay and total pay and
write data
Once execution of your program has completed, the output file should contain your name, course name and date, each on a new line, followed by the employee records including their total pay.
Ex:
John Doe
Software Design & Programming II
Employee IDHours WorkedPay Rate Total Pay
