Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Lab-Homework - Use the table below to compute the biweekly salary for the employees. The data members must be defined under the access specifiers as

image text in transcribed
image text in transcribed
Lab-Homework - Use the table below to compute the biweekly salary for the employees. The data members must be defined under the access specifiers as indicated in the table. You may define all your member functions as public. You are expected to complete the following: 1. Transformers: a. Create a data entry member function (Transformers) that will be used to manually enter the data from the table to transform the data members (instance) of the object b. Create a member function that computes the salary and updates data members to prepare them for printing 2. Iterators: a. Create a member function to print the pay slip. The function should only print earnings and deductions as specified in the report format. 3. From Main(): Object creation and initialization a. Create an object/variable for the MD & CEO. Call the data entry function in the class to enter the data manually. Call the function that computes salary. b. Create an array of objects for the remaining employees: Example: className objectArray(4); and use the data entry function to manually enter each object's data from the table provided. Run the salary computation function on each of the objects in the array. 4. Print out the pay slips using the report format given. Note that the printing must be done from the Main(). Implies that private data (e.g., ID. No, names etc..) must be retrieved using observer functions. While you use the iterator function which you created in the class to print the pay slip details. Have fun! Classes: Monthly Payroll Computation Lesson 3 - Lab Table: Access Specifiers Priv. Priv. Protect Protect Protect Pub. Pub. Pub. Priv. Protect Protect Protect Expected Contract Hours Days Annual ID. O Type Office First Name Last Name Rate Per Day Worked Salary Gross YTD Ded YTD Net YTD 1001 Full-Time MD & CEO Michael Smith 147,000.00 2011 Part-Time Receptionist Maria Rodriguez 20 10 14 2010 Part-Time Administrator James Robert 25 8 12 2012 Part-Time Office Assistant Kenny Mercedes 22 12 12 1002 Full-Time Manager Kyndra Hernandez 75,000.00 Deductions (Public: Federal Tax-20of Gross State Tax. 10% of Gross Medical Plan -5% of Gross Dental Plan- 3% of Gross Retirement Plan - 2.5% of Gross Note: Full Time Gross (Annual salary/1272 (weekly) Part-Time Gross Rate Hours Per Day Days Worked (Blweekly) Net PayGross - (Al Deductions) Gross YTD - Gross Ded. YTD - (All Deductions) Name: Lastname, Firstname Official Positon: Deductions Earnings Hours: Hours Per Day Days Worked (Part-Time only) Report Format: ID. No.: Contract: Description Gross Pay Federal Tax -20% State Tax -10% Medical Plan-5 Dental Plan-3% Retirement Plan - 2.5 Sub-Totalt Net Pay: mm

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Spatial Databases A Tour

Authors: Shashi Shekhar, Sanjay Chawla

1st Edition

0130174807, 978-0130174802

More Books

Students also viewed these Databases questions