Q.
Consider the following classes:
public class
Test {
public static void test() {
this.print();
}
public static void print() {
System.out.println("Test");
}
public static void main(
String args []) {
test();
}
}
What is the result of compiling and running this class?
A.The string Test is printed to the standard out.
B.A runtime exception is raised stating that an object has not been created.
C.Nothing is printed to the standard output.
D.An exception is raised stating that the method test cannot be found.
E.An exception is raised stating that the variable this can only be used within an instance.
F.The class fails to compile stating that the variable this is undefined.
************
given answer is F.but I cann't know it clearly.if you think the answer is right,please explain it to me in detail.thanks for your reply!