I need a Java program that will calculate an estimated tax for either a single or married taxpayer, given a keyboard income entry.
After the income is entered, a code status “S?? for single or “M?? for married is entered.
Two classes are needed.
1. A Tax class with a main() method for keyboard entry of income and code status values.
2. A TaxReturn class to calculate the tax based on the input.
The input values should be passed from the Tax class to the TaxReturn class through the instantiation of a TaxReturn object. The instantiation could take a form such as:
TaxReturn aTaxReturn = new TaxReturn(income, status);
For taxpayers, two tax rates are needed: 15% and 30%.
1. For single taxpayers, the cutoff rate of 15% is for amounts below $10,000 and 30% for amounts greater than $10,000.
2. For married taxpayers, the cutoff rate is 15% for amounts below $20,000 and 30% for amounts greater than $20,000.
The program output should show the code status, income, and amount of the tax.
The program files are: [url removed, login to view] and TaxReturn.java.
The program files needed are: [url removed, login to view] and TaxReturn.java.
Code able to run on all Win 98/ME/XP platforms.