Write a java program name it incometax that reads from the


Program #2 (10 points): Write a Java program (name it IncomeTax) that reads from the user annual income as
integer value. The program then, on separate lines, prints out the income amount along with the tax bracket using the
following scale:
Annual income <= $50,000 tax bracket: 5%
$50,000 < Annual income <= $100,000 tax bracket: 15%
$100,000 < Annual income <= $150,000 tax bracket: 20%
$150,000 < Annual income <= $250,000 tax bracket: 30%
$250,000 < Annual income <= $500,000 tax bracket: 35%
$500,000 < Annual income tax bracket: 50%
Make sure to properly label your output, format the output (using $ and %), and use escape character (t) to lineup the
outputs after the labels. Document your code and organize and properly space out the outputs.

Program #3 (10 points): Write a Java program (name it PhoneBill) that that calculates the bill for a cellular
telephone company. The company offers two types of service: regular and premium. The rates vary depending on the
type of service. The rates are computed as follows:
Regular service: $10.00 plus first 50 minutes are free. Charges for over 50 minutes are $0.20 per minute.
Premium service: $25.00 plus:
a. For calls made from 6:00AM to 6:00PM, the first 75 minutes are free; charges for over 75 minutes are $0.10
per minute.
b. For calls made from 6:00PM to 6:00AM, the first 100 minutes are free; charges for over 100 minutes are
0.05 per minute.
Your program should prompt the user to enter an account number, a service code (type char), and the number of
minutes the service was used. A service code r (or R) means regular service; while code p (or P) means premium
service.
For the premium service (code P), the customer may be using the service during both the day and at night. Therefore,
you must ask the user to input the number of minutes used during the day and the number of minutes used at night.
The program should output, on separate lines and with proper labels, the account number, service type, number of
minutes the service was used, and the amount due from the user.

Solution Preview :

Prepared by a verified Expert
JAVA Programming: Write a java program name it incometax that reads from the
Reference No:- TGS0631036

Now Priced at $40 (50% Discount)

Recommended (94%)

Rated (4.6/5)