Answered step by step
Verified Expert Solution
Question
1 Approved Answer
For this Assignment, submit the following program: Create a TaxReturn class with fields that hold a taxpayer's Social Security number last name, first name, zip
For this Assignment, submit the following program: Create 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. The program will calculate the tax liability based on annual income and the percentages in the following table Marital Status TOTAL Income in US Dollars Single Married 0-15000 12% 10% 15001-40000 20% 18% 40001 and up 239 The TaxReturn class should have the Calculate Tax method to calculate tax liability The TaxReturn class should have the Calculate Tax method to calculate tax liability Note: the Tax class does not have the main method and can be used for objects instantiations only Create ShowTax driver class with the main method ShowTax class instantiates my Tax object of the TaxReturn type and sets up its fields to values entered by a user. These data will be later retrieved from the object fields and displayed When accepting a user's input prompt the user to enter the data needed to output a summary of the information gathered Make sure to ask for the information in the format you would like it from the user and adhere to the following . 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 No negative incomes are allowed, so the value must be above zero if such input is attempted You will use the String Builder class to format the output results The output for each data set should be displayed making use of the JOptionPane class Test your application with data in the three data sets below and take the screen shots for each Data ser 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, mantal 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. In the java files provide the comments on code blocks their scope and functionality as you write codes in the TaxReturn class and Show Tax class. Include the proper application header in the ShowTax Java file Submit one Word document with all the screenshots for each data set for code and output your comments and explanations on your solution and Tax Return.java and Show Tax.java files Zip all the files into the same zip archive and submit it as your deliverable
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started