In Python Make a new class called Electric_Car which posses all the methods and attributes of the Car class. In addition set a new attribute called charge_count that starts from 0 for any newly...



In Python Make a new class called Electric_Car which posses all the methods and attributes of the Car class. In addition set a new attribute called charge_count that starts from 0 for any newly constructed electric car. Write a new method called charge() that each time we call it for a given electric car, updates the charge_count by adding 1 unit. Now construct a new electric car instance with following attributes: Make: Tesla; Model: s; Year: 2018. Call the trip() method to update odometer with a trip of 200 miles. Also call the charge() method to update the charge count twice.




Jun 11, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here