Respuesta :
Answer:
public ApartmentBuilding(Address address, int squareFootage, int totalUnits) {
super(address, squareFootage);
this.totalUnits = totalUnits;
}
Answer:
It seems you already answered your own question, but let me explain the steps so that it will all be clear for you.
Explanation:
A constructor has no return type, has the name as the class name, and can take parameters.
According to the requirements, the ApartmentBuilding constructor takes three parameters: address, squareFootage, and totalUnits. Inside the body of the constructor, we need to initialize these variables.
Be aware that the address and squareFootage is initialized by using super keyword. That means, the constructor of the parent class - Building is invoked.