
class Clidder { private final void flipper() { System.out.println("Clidder"); }
}
public class Ex3 extends Clidder { public final void flipper() { System.out.println("Clidder"); }
public static void main(String[] args) {
new Ex3().flipper();
}
}

class Clidder {
private final void flipper() {
System.out.println("Clidder");
}
}
public class Ex3 extends Clidder {
public final void flipper() {
System.out.println("Clidder");
}
public static void main(String[] args) {
new Ex3().flipper();
}
}
In the above code there is a super class Clidder which is having a method flipper(). The class Ex3 extends the superclass Clidder.It means Ex3 is the subclass of Clidder class. The subclass is having the property that it can inherit all the properties and methods of its super class.Here the Ex3 class inherits the method flipper() of its super class. In the main method, it calls that method.
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.