public class
Test {
public void a(Object o) { System.out.println("object"); }
public void a(
String s) { System.out.println("string"); }
public static void main(String[] args) {
new Test().a(null);
}
}
Why does the above code compile and produce the output of string?
Thanks,
Sandeep