Java Assignment Use Class Car Represent Car Travels Various Destinations Car Fuel Economy Q37286483

In JAVA

In this assignment you will use a class Car to represent acar that travels to various destinations. Your car has afuel economy rating of 32.3 miles per gallon. The gas tank holds19.5 gallons. Your program will need to simulate two trips: 1) BCto Yosemite Valley, and 2) BC to Washington, D.C.. For each tripyou will start with a full tank of gas. The output should look asfollows.

Trip one: Bakersfield College to Dodger Stadium

Mileage: 204

Trip two: Bakersfield College to Washington, D.C.

Mileage: 2,686

The constructor will set the fuel efficiency rating to 32.3 mpgand the initial fuel level for each trip to

OR
OR

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.