C is correct. The code will compile without any error and also will not give any run time error. The variable p refers to the Child class object. The statement p.method2() on execution will first look for method2() in Child class. Since there is no method2() in child class, the method2() of Parent class will be invoked and thus "Parent's method2()" will be printed. Now from the method2() , there is a call to method1(). Please note that method1() of Parent class is private, because of which the same method (method1() of Parent class) will be invoked. Had this method(method1() of Parent class) been public/protected/friendly (default), Child's class method1() would be called. Thus C is correct answer.
I don't understand why it matters whether the Parent's method is private or all of the above.
[ Jess added
UBB [code] tags to preserve whitespace, check 'em out! She also added a bit more descriptive title... ]
[ March 11, 2003: Message edited by: Jessica Sant ]