Question: 1 Implement Drivable Open the le Drivable . java and inspect the interface we have given you. The Drivable interface contains two methods that every

 1 Implement Drivable Open the le Drivable . java and inspect
the interface we have given you. The Drivable interface contains two methods

1 Implement Drivable Open the le Drivable . java and inspect the interface we have given you. The Drivable interface contains two methods that every implementing class MUST have, which are movingForwaIdO and movingBackvardO. We know we want what we drive to move in those two directions but we don't care how, we leave that specicatiOn fer the class to decide. Now, write an implementation for the following two classes. a public class Bike implements Drivable This Class should be an implementation of the interface Drivable. java. Make each method write the name of the class + \"Moving\" and then the direction (forwards or backwards). 0 public class Scooter implements Drivable This class should be an implementation of the interface Drivable. java. Make each method write the name of the class + \"Moving\" and then the direction (forwards or backwards). For example, calling movingBackwardC) on a Bike object should output \"Bike Moving Backward\". Milestone 1: To test your classes, create a le VehicleTester. java that contains a. main method that tests each of your move methods, and show your code to your TA

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Mathematics Questions!