From 7c5cd3748ab690cd3b3c41a56082a0c0e0225b95 Mon Sep 17 00:00:00 2001 From: bytesparallel Date: Thu, 30 Jun 2022 13:41:47 -0500 Subject: [PATCH] have inheritance and interface example complete --- fleet.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/fleet.py b/fleet.py index 796fff5..23393c4 100644 --- a/fleet.py +++ b/fleet.py @@ -66,6 +66,9 @@ class Train(GroundVehicle): def displayCarCount(self): print(self.noOfCarsAttached) + def travel(self): + print("Speed 60mph, Direction E") + Train1 = Train(20, 2) -Train.displayCarCount() \ No newline at end of file +Train1.displayCarCount() \ No newline at end of file