What will be the output of this program?
class Demo {
int num;
Demo() {
this(100);
System.out.println("Default Constructor");
}
Demo(int n) {
num = n;
System.out.println("Parameterized Constructor");
}
}
public class Main {
public static void main(String[] args) {
Demo obj = new Demo();
}
}
Default Constructor
Parameterized Constructor
Parameterized Constructor
Default Constructor
Compilation Error