Question: Java Programming: Consider an interface Runablex with the methods: RunPeople and RunHorse. This interface will be used from the two classes: People and Horse. Using
Java Programming:
Consider an interface Runablex with the methods: RunPeople and RunHorse.
This interface will be used from the two classes: People and Horse.
Using array with these two classes prepare a program that print all together:
Jack (a person) is running
Jeff (a person) is running
Jace(a person) is running
horse1 (a horse) is running
horse2 (a horse) is running
horse3 (a horse) is running
//create interface Runablex
//create class People that implement Runablex
//create class Horse that implement Runablex
//create the main method
public class Runablex
//array of classes
//creatre the main method
public class Runablerun
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
