Answered step by step
Verified Expert Solution
Link Copied!
Question
1 Approved Answer

Please write this Java program as simple as possible and with comments throughout to explain what is happening! Thank you! Proaram 3 410 points): Write

image text in transcribed
Please write this Java program as simple as possible and with comments throughout to explain what is happening! Thank you!
Proaram 3 410 points): Write a Java program (name it PhoneBi11) 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 used each month are included in the $10.00 monthly service fee. Charges for minutes used over 50 minutes each month are $0.20 per minute. Premium service: $25.00 plus: a. For calls made from 6:00AM to 6:00PM, the first 75 minutes used each month are included in the $25.00 monthly service fee; charges for minutes used over 75 minutes each month are $0.10 per minute b. For calls made from 6:00PM to 6:00AM, the first 100 minutes used each month are included in the $25.00 monthly service fee; charges for minutes used over 100 minutes each month 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 (do not prompt for total minutes). 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

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image
Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

PC Magazine Guide To Client Server Databases

Authors: Joe Salemi

1st Edition

156276070X, 978-1562760700

More Books

Students explore these related Databases questions