OOP 7: Adding Parameters

OOP 7: Adding Parameters

7.1. Add the fuel_used attribute inside __init__ method of Car class without changing its arguments and assign it a value of 0 liters.

7.2. Add the fuel_consumption attribute inside __init__ method of Car class, passing it as a method argument with default value of 7 (liters/100 km).

7.3. Add a drive method to the Car class that takes the distance argument of type int (km). If an instance of class had started - increment fuel_used with the proper value ( that is based on fuel_consumption variable and distance parameter values) and display the message "Currently driven {distance} km, total fuel used - {fuel_used}...

You should be an authorized user in order to see the full description and start solving this mission.