Sail E0 Webinar
Question
Class MyClass{      MyClass(){            System.out.print("one");      }      public void myMethod(){            this();            System.out.print("two");      }} public class TestClass{      public static void main(String args[]){            MyClass obj = new MyClass();            obj.myMethod();      }}
Options:
A .  one one two
B .  Compilation Error
C .  one Exception
D .  two one one
E .  None of these
Answer: Option B

Submit Your Solution Below and Earn Points !
Next Question

Submit Solution

Your email address will not be published. Required fields are marked *

Latest Videos

Latest Test Papers