Question: Write a program that asks the user to enter the number of hours for electric usage and calculates the charge according to the following: a
Write a program that asks the user to enter the number of hours for electric usage and calculates the charge according to the following:
a Regular charge is $hour
b Charge for hours over is $hour Declare charge as double. Make sure charge is formatted to two digits after the decimal point.
eg If usage is hours, charge is cents.
eg If usage is hours, charge is $
eg If usage is hours, charge is $
eg If usage is hours, charge is $
egIf usage is hours, charge is $
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
