Explanation of output
- by Anon
My program
class Building {
Building() {
System.out.print("b ");
}
Building(String name) {
this();
System.out.print("bn " + name);
}
};
public class House extends Building {
House() {
System.out.print("h "); // this is line# 1
}
House(String name) {
this(); // This is line#2
System.out.print("hn " + name);
}
public…