1. Write the output of these code block without running (1) class Person{ public Person () { System.out.println("hi!");
Posted: Tue Jun 07, 2022 12:38 pm
1. Write the output of these code block without running (1) class Person{ public Person () { System.out.println("hi!"); } public Person (String s) { this(); System.out.println("I am "+s); } } public class Who extends Person { public Who () { this ("I am Tony"); } public Who (String s) { super (s); System.out.println("How do you do?"); } public static void main(String args[]) { Who w = new Who (); }