/electricCompanyCharges

An electric company is charging its consumers based on the numbers of units consumed.

Primary LanguageJava

Electric Company Charges

  • An electric company is charging its consumers based on the following table:
Numbers of Units Consumed Charges/Unit
For the first 200 units 2.5
For the next 300 units 3.5
Over 500 units 5

Depending on the day of the payment, it will have a discount or a surcharge.

  • If consumers pays within 15 days a discount of 10% is given.
  • If consumers pays after 15 days a surcharge of 5% will be added.