You have been hired by up and coming company Gekko & Co. to create a pay...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
You have been hired by up and coming company Gekko & Co. to create a pay stub calculator for their employees. Their employees are paid only once per month. The pay stub will show take-home pay for each pay period after withholdings for taxes and retirement fund. Gekko would like your program to read the following input for an employee: 1. Employee name. 2. Month and year the employee was hired. 3. Hours worked in the pay period (between 0 and 350). 4. Job title, and 5. Hourly pay rate. After reading in these values, your program must perform two kinds of calculation: 1. Number of vacation hours earned. Vacation calculations are based on the number of months worked. and 2. Net wages to be paid. Gekko employees are required to contribute a portion of their pay to their retirement fund each pay period. This retirement fund withholding is taken pre-tax. Tax withholding will then be calculated. Data Members (Fields) Name, anniversary month, anniversary year, hours worked, job title, hourly pay rate, number of months worked, vacation hours, gross pay, retirement withholding, tax withholding, net pay. Two Constructors 1. PayStub(): Default constructor to initialize the data members. 2. PayStub( String name, int anniversary Month, int anniversary Year, int hours, String title, double payRate): Parameterized constructor to initialize the data members. This work is a derivative of "PAI: Meep Inc. Pay Stub Calculator" by Chris Mayfield, 000 James Madison University, used under CC BY. This work is licensed under CC BY by Matthew Magnusson, University of New Hampshire. Member Methods Pay Stub Object Assignment Java 100 Points 3. String getName(): Returns the name of the employee 4. int getMonth(): Returns the anniversary month of the employee 5. int getYear() : Returns the anniversary year of the employee 6. int getHours(): Returns the number of hours worked by the employee 7. String getTitle(): Returns the job title of the employee 8. double getPay Rate(): Returns the hourly pay rate of the employee 9. int numMonthsWorked(): Calculate and return the number of months worked based on the anniversary month and year and the current pay period month and year. Note: The current pay month = 1, current pay year = 2019. 10. double vacationHours() Calculate the vacation hours earned this pay period as the number of months worked times the vacation rate of 8.25 vacation hours per month. Vacation hours are reported to two significant digits. For example, 0.12 or 12.79. 11. double gross Pay(): Calculate gross pay, defined as the hours worked times pay rate. 12. double retHold() Calculate the retirement withholding for the employee, which is defined as the gross pay times the retirement rate of 5.2%. 13. double tax() : Calculate and return the tax withholding for the employee, which is defined as the taxable income (gross pay minus retirement withholding) times the tax rate of 28.0%. 14. double netPay() Calculate the net pay which is gross pay minus retirement minus tax withholdings. 15. void drawLogo(): Print the company logo Gekko & Co. "$" 16. void printInfo(): Print the details of the employee including the gross pay, taxes and net pay. BIG HINT: to match the output in Gradescope for printing gross pay, retirement, tax, and net pay use the following format string with the printf method "%7.2f\n". Otherwise you may have trouble having the spacing match up correctly in output. NOTE: 1. When implementing the Java code, the source file should be named PayStub.java. BY NO SA This work is a derivative of "PA1: Meep Inc. Pay Stub Calculator" by Chris Mayfield, James Madison University, used under CC BY. This work is licensed under CC BY by Matthew Magnusson, University of New Hampshire. Output Gekko & Co. "$" Pay Period: Name: Title: Anniversary: Months Worked: 1/2019 Karin Nadya Computer System Analyst 4/2015 45 months Vacation hours: 371.25 Gross Pay: Retirement: Tax: $7160.40 $ 372.34 $1900.66 Net Pay: $4887.40 Pay Stub Object Assignment Java 100 Points Submission Submit your PayStub.java file to Gradescope before the deadline. You may submit more than one time, the last attempt before the deadline is reached is the one that is graded. Before uploading your program, be sure to complete the following steps carefully: 1. Your input and output should match the input and output test cases exactly, character for character. 2. Make sure all your variables are declared at the beginning of the main method, before any other statements. 3. Check that you have written the proper Javadoc @author and @version tags in the appropriate place. 4. Run Checkstyle and eliminate ALL warnings about your code. (You should be doing this along the way and not just at the end of the assignment.) BY NC SA This work is a derivative of "PA1: Meep Inc. Pay Stub Calculator" by Chris Mayfield, James Madison University, used under CC BY. This work is licensed under CC BY by Matthew Magnusson, University of New Hampshire. Pay Stub Object Assignment Java 100 Points 2. Provide a meaningful Javadoc comment at the top, including @author and @version tags. 3. Write concise comments (using //) wherever required to explain your logic and intuition. Sample Input/Output Input Your program's main method will need to read and store employee information while displaying the prompts exactly as shown in the following example: Enter your Fullname: Karin Nadya Enter your Anniversary Month (1-12): 4 Enter your Anniversary Year: 2015 Enter your hours worked this pay period (0-350): 170 Enter your Job Title: Computer System Analyst Enter your pay rate: 42.12 CC BY NO SA This work is a derivative of "PA1: Meep Inc. Pay Stub Calculator" by Chris Mayfield, James Madison University, used under CC BY. This work is licensed under CC BY by Matthew Magnusson, University of New Hampshire. You have been hired by up and coming company Gekko & Co. to create a pay stub calculator for their employees. Their employees are paid only once per month. The pay stub will show take-home pay for each pay period after withholdings for taxes and retirement fund. Gekko would like your program to read the following input for an employee: 1. Employee name. 2. Month and year the employee was hired. 3. Hours worked in the pay period (between 0 and 350). 4. Job title, and 5. Hourly pay rate. After reading in these values, your program must perform two kinds of calculation: 1. Number of vacation hours earned. Vacation calculations are based on the number of months worked. and 2. Net wages to be paid. Gekko employees are required to contribute a portion of their pay to their retirement fund each pay period. This retirement fund withholding is taken pre-tax. Tax withholding will then be calculated. Data Members (Fields) Name, anniversary month, anniversary year, hours worked, job title, hourly pay rate, number of months worked, vacation hours, gross pay, retirement withholding, tax withholding, net pay. Two Constructors 1. PayStub(): Default constructor to initialize the data members. 2. PayStub( String name, int anniversary Month, int anniversary Year, int hours, String title, double payRate): Parameterized constructor to initialize the data members. This work is a derivative of "PAI: Meep Inc. Pay Stub Calculator" by Chris Mayfield, 000 James Madison University, used under CC BY. This work is licensed under CC BY by Matthew Magnusson, University of New Hampshire. Member Methods Pay Stub Object Assignment Java 100 Points 3. String getName(): Returns the name of the employee 4. int getMonth(): Returns the anniversary month of the employee 5. int getYear() : Returns the anniversary year of the employee 6. int getHours(): Returns the number of hours worked by the employee 7. String getTitle(): Returns the job title of the employee 8. double getPay Rate(): Returns the hourly pay rate of the employee 9. int numMonthsWorked(): Calculate and return the number of months worked based on the anniversary month and year and the current pay period month and year. Note: The current pay month = 1, current pay year = 2019. 10. double vacationHours() Calculate the vacation hours earned this pay period as the number of months worked times the vacation rate of 8.25 vacation hours per month. Vacation hours are reported to two significant digits. For example, 0.12 or 12.79. 11. double gross Pay(): Calculate gross pay, defined as the hours worked times pay rate. 12. double retHold() Calculate the retirement withholding for the employee, which is defined as the gross pay times the retirement rate of 5.2%. 13. double tax() : Calculate and return the tax withholding for the employee, which is defined as the taxable income (gross pay minus retirement withholding) times the tax rate of 28.0%. 14. double netPay() Calculate the net pay which is gross pay minus retirement minus tax withholdings. 15. void drawLogo(): Print the company logo Gekko & Co. "$" 16. void printInfo(): Print the details of the employee including the gross pay, taxes and net pay. BIG HINT: to match the output in Gradescope for printing gross pay, retirement, tax, and net pay use the following format string with the printf method "%7.2f\n". Otherwise you may have trouble having the spacing match up correctly in output. NOTE: 1. When implementing the Java code, the source file should be named PayStub.java. BY NO SA This work is a derivative of "PA1: Meep Inc. Pay Stub Calculator" by Chris Mayfield, James Madison University, used under CC BY. This work is licensed under CC BY by Matthew Magnusson, University of New Hampshire. Output Gekko & Co. "$" Pay Period: Name: Title: Anniversary: Months Worked: 1/2019 Karin Nadya Computer System Analyst 4/2015 45 months Vacation hours: 371.25 Gross Pay: Retirement: Tax: $7160.40 $ 372.34 $1900.66 Net Pay: $4887.40 Pay Stub Object Assignment Java 100 Points Submission Submit your PayStub.java file to Gradescope before the deadline. You may submit more than one time, the last attempt before the deadline is reached is the one that is graded. Before uploading your program, be sure to complete the following steps carefully: 1. Your input and output should match the input and output test cases exactly, character for character. 2. Make sure all your variables are declared at the beginning of the main method, before any other statements. 3. Check that you have written the proper Javadoc @author and @version tags in the appropriate place. 4. Run Checkstyle and eliminate ALL warnings about your code. (You should be doing this along the way and not just at the end of the assignment.) BY NC SA This work is a derivative of "PA1: Meep Inc. Pay Stub Calculator" by Chris Mayfield, James Madison University, used under CC BY. This work is licensed under CC BY by Matthew Magnusson, University of New Hampshire. Pay Stub Object Assignment Java 100 Points 2. Provide a meaningful Javadoc comment at the top, including @author and @version tags. 3. Write concise comments (using //) wherever required to explain your logic and intuition. Sample Input/Output Input Your program's main method will need to read and store employee information while displaying the prompts exactly as shown in the following example: Enter your Fullname: Karin Nadya Enter your Anniversary Month (1-12): 4 Enter your Anniversary Year: 2015 Enter your hours worked this pay period (0-350): 170 Enter your Job Title: Computer System Analyst Enter your pay rate: 42.12 CC BY NO SA This work is a derivative of "PA1: Meep Inc. Pay Stub Calculator" by Chris Mayfield, James Madison University, used under CC BY. This work is licensed under CC BY by Matthew Magnusson, University of New Hampshire.
Expert Answer:
Related Book For
Introduction To Corporate Finance
ISBN: 9781118300763
3rd Edition
Authors: Laurence Booth, Sean Cleary
Posted Date:
Students also viewed these programming questions
-
Wayland Custom Woodworking is a firm that manufactures custom cabinets and woodwork for business and residential customers. Students will have the opportunity to establish payroll records and to...
-
Background: A new ownership group has recently purchased ABC Liquors. You have been hired by the new management team to analyze their sales data for the past year and provide them with insights about...
-
Suppose a city finds that its express highways into the city are congested and it is considering two remedies: (1) imposing a congestion charge on all users of its expressways during the peak periods...
-
What are the benefits of the proposed TTIP?
-
A personnel manager has found that historically the scores on aptitude tests given to applicants for entry level positions follow a normal distribution with a standard deviation of 32.4 points. A...
-
Consider a coal mining cart being loaded with coal as it moves along a horizontal track. Suppose that a tractor exerts a constant horizontal force on this cart. Is there any situation in which the...
-
A business student at Nowledge College must complete a total of 65 courses to graduate. The number of business courses must be greater than or equal to 23 the number of non business courses must be...
-
The Admiral Shares of the Vanguard Long-Term Bond Index Fund (symbol: VBLAX) had net assets of $8.6 Bn as of 3/10/23. a) Using the Internet or some other public source of information, determine the...
-
Complete Form 941 for the 4th quarter for TCLH Industries (which is located at 202 Whitmore Avenue, Durham, NC 27701; Employer Identification #44-4444444). Assume that all necessary deposits were...
-
Although its own operations have shown no growth over the past decade, Hammerworks Inc. has built up a significant cash balance ($2.9 billion) in anticipation of a collapse in equity prices which it...
-
There are required 2 0 0 0 kW of compressor power to handle air adiabatically from 1 atmosphere, 2 7 oC , to 3 0 5 kPaa. The initial air velocity is 2 0 m / s and the final velocity is 8 5 m / s . a...
-
} Find the recurrence relation for the given pseudo code and calculate its time complexity using the substitution method. Verify the time complexity obtained with the substitution method using the...
-
= The position of a particle moving in a xy plane is given by 7 (5+ - 6t)i + (2 2+) within meters and t in seconds. In unit- vector notation, calculate for t = 2.00 s.
-
A boiler is rated at 2 5 0 0 kW . If the boiler efficiency is 8 5 % . ( a ) find the consumed amount of fuel in J / hr . ( b ) discuss the energy saving opportunities in boilers. ( c ) discuss the...
-
A triangle is formed by taking a point on the unit circle (cos, sin 0) and forming the lines connecting each pair of points among (0,0), (cos 0,0), and (cos, sin 0) as in the graph below. When the...
-
Find all the solutions of the system of equations *, + 2x, x, = 1, 3x, 2x, + 2x, = 2, 7x, - 2x, + 3x, = 5
-
1. Following are information about Alhadaf Co. Cost incurred Inventory Purchases Sales Adverting expense Salary Expense Depreciation Beginning Inventory Ending Inventory Amount 118,000 350.000 90,000...
-
In order for the M&M irrelevance theorem to hold, what key assumptions must be met?
-
Carla is the CEO of The Superior Sausage Company (a Canadian firm, listed on the Toronto Stock Exchange) and believes that the best way for the company to grow is through acquisitions. She has...
-
Suppose the spot exchange rate is C$1.4665 per 1, while the six-month forward rate is C$1.50 per euro. What will be the profit for an investor who assumes a 100,000 long position in the forward...
-
Polaris Industries has \(\$ 1,250,000\) available for additional innovations on the Victory Vision motorcycle. These include the five indivisible, equal-lived alternatives, each of which guarantees...
-
Sebastian is about to compare a set of mutually exclusive and indivisible alternatives using a ranking approach. Which of the following is not an appropriate measure of worth? a. Present worth b....
-
CustomMetalworks is considering expanding their cable fabrication business for towers, rigging, winches, and many other uses. They have available \(\$ 250,000\) for investment and have identified the...
Study smarter with the SolutionInn App