λFPAI
Practice/Car Basics

Car Basics

Beginner

Model a Car class with make, model, year, and fuel_level.

Add methods start_engine(), drive(distance), and refuel(amount). Create a few car objects and simulate a short trip.

OOP Focus: Simple behavior modeling with method calls and state changes.

Note: This is statement-only in the current Practice version; stdout should be empty.

Loading editor...

Output

Run or submit to see output.