1.

What Will Be The Output Of The Following Program? Interface X { Char C = 'a'; Char Methodx(); } Class Y Implements X { { System.out.println(c); } Public Char Methodx() { Char C = This.c; Return ++c; } } Public Class Mainclass { Public Static Void Main(string[] Args) { Y Y = New Y(); System.out.println(y.methodx()); System.out.println(y.c); System.out.println(x.c); } }

Answer»

A

B

A

A

A

B

A

A



Discussion

No Comment Found

Related InterviewSolutions