Untitled
unknown
plain_text
4 years ago
507 B
5
Indexable
public class Main { public static void main(String[] args) { Bike b = new Bike(); b.fun(); } } class Rower { public Rower() { System.out.println("rower constructor"); } public void fun(){ System.out.println("rower fun"); } } class Bike extends Rower { public Bike() { System.out.println("bike constructor"); } public void fun() { System.out.println("bike func"); super.fun(); } }
Editor is loading...