logo

Crowdly

Consider the following class hierarchy: public class Vehicle {    private St...

✅ The verified answer to this question is available below. Our community-reviewed solutions help you understand the material better.

Consider the following class hierarchy:

public class Vehicle

{

   private String type;

   public Vehicle(String type)

   {

      this.type = type;

   }

   public String displayInfo()

   {

      return type;

   }

}

public class LandVehicle extends Vehicle

{

   public LandVehicle(String type)

   {

      . . .

   }

}

public class Auto extends LandVehicle

{

   public Auto(String type)

   {

      . . .

   }

   public String displayAutoType()

   {

      return _____;

   }

}

Complete the code in the Auto class method named displayAutoType to return the type data. 

0%
0%
0%
100%
More questions like this

Want instant access to all verified answers on moodle.lsu.edu?

Get Unlimited Answers To Exam Questions - Install Crowdly Extension Now!