Why this code will print int?
public static void main(String[] args) {
short s = 5;
A(s);
}
public static void A(int a){
System.out.println("int");
}
public static void A(Short a){
System.out.println("short");
}
See Question&Answers more detail:os