class Room { private double width; private double height; public Room(double width, double height){ this.width = width; this.height =height; } public final double getArea(){ return width*height; } } class LivingRoom extends Room{ // The constructor simply calls the parent's constructor using super() public LivingRoom(double width, double height){ super(width,height); } // Not allowed to override getArea() here, because this method is final //public double getArea(){ // return width*height; // } } public class SuperAndFinal { public static void main(String[] args) { // TODO Auto-generated method stub LivingRoom myLivingRoom = new LivingRoom(5,3); double area = myLivingRoom.getArea(); System.out.println(area); } }