Problem Description The electric company charges according to the following rate
ID: 3626916 • Letter: P
Question
Problem Description
The electric company charges according to the following rate schedule:
9 cents per kilowatt-hour (kwh) for the first 300 kwh
8 cents per kwh for the next 300 kwh (up to 600 kwh)
6 cents per kwh for the next 400 kwh (up to 1,000 kwh)
5 cents per kwh for all electricity used over 1,000 kwh.
Write a function to compute and return the total charge for each customer. Write a main function to call the charge calculation function using the following data:
Customer Number Kilowatt-hours used
123 725
205 115
464 600
596 327
601 915
613 1,011
722 47
The program should print a three-column chart listing the customer number, the kilowatt-hours used, and the charge for each customer. The program should also compute and print the number of customers, the total kilowatt-hours used, and the total charges.
Explanation / Answer
hi there u didn`t mintion the language i wrote in c++ PLEASE RATE #include using namespace std; int calculate(int N) { int rate=0; for(int count=1;countRelated Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.