Question: In Java Write a program that calculates potential savings when you switch driving from a gasoline-powered car to an electric vehicle (EV). The program takes

In Java

Write a program that calculates potential savings when you switch driving from a gasoline-powered car to an electric vehicle (EV). The program takes the following inputs from the user Local fuel price/gallon, Estimated MPG of gas vehicle, Estimated kWh per mile for EV, Utility kWh rate, Total miles are driven per year, and displays the potential total $ savings per year.

The formula of savings is [ (total miles driven / MPG) x gas price per gallon ] - [ (total miles driven x EV kWh consumption per miles) x utility rate per kWh].

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!