View the step-by-step solution to:

Hello, I will have to be creating a TaxReturn class with fields that hold a taxpayer's Social Security number, last name, first name, zip code,

Hello,


I will have to be creating a TaxReturn class with fields that hold a taxpayer's Social Security number, last name, first name, zip code, annual income, marital status and the number of vehicles owned. This program will have to be calculating the tax liability based on annual income and the percentages in the table below. The TaxReturn class should have the CalculateTax method to calculate tax liability. I will then have to start creating a ShowTax driver class with the main method. ShowTax class instantiates myTax object of the TaxReturn and sets up its fields to values entered by a user. This data will then need to be retrieved from the object fields and displayed. When accepting a user's input, I will have to prompt the user to enter the data needed to output a summary of the information gathered. I will be having to ask for the information in the format I would like it inputted from the user and it must abide by the following rules: If the Social Security number contains more or less than 10 digits then reprompt for the information again, Marital status must be either 'S' or 's' or 'M' or 'm', and No negative incomes are allowed, so the value must be above zero if such input is attempted. I will have to be using the StringBuilder class to format the output results. I will have to display the output for each data set making use of the JOptionPane class using the data in the sets below.


Data set 1 to input:

Social Security number 888-99-5623, last name Jones, first name Michael, zip code 12345, annual income 73564, marital status m, number of vehicles owned 5.

Data set 2 to input:

Social Security number 899-99-5624, last name Jackson, first name Jane, zip code 62354, annual income 23564, marital status M, number of vehicles owned 1.

Data set 3 to input:

Social Security number 522-97-2341, last name Smith, first name Darrell, zip code 20156, annual income 60270, marital status M, number of vehicles owned 2.


Can you please assist me with this code? I'm constantly running into errors.


Thanks in advance...





scale.PNG

scale.PNG

Recently Asked Questions

Why Join Course Hero?

Course Hero has all the homework and study help you need to succeed! We’ve got course-specific notes, study guides, and practice tests along with expert tutors.

-

Educational Resources
  • -

    Study Documents

    Find the best study resources around, tagged to your specific courses. Share your own to gain free Course Hero access.

    Browse Documents
  • -

    Question & Answers

    Get one-on-one homework help from our expert tutors—available online 24/7. Ask your own questions or browse existing Q&A threads. Satisfaction guaranteed!

    Ask a Question