public class P2 {
static
{
System.out.println(new Long(10).equals(new Integer(10)));
}
public static void main(String [] args)
{
}
}
A. Compile error
B. Runtime error
C. Nothing printed
D. true
E. false
s***8 发帖数: 1136
2
f
w*****g 发帖数: 1415
3
false
w****u 发帖数: 3147
4
答案呢?
【在 u****s 的大作中提到】 : public class P2 { : static : { : System.out.println(new Long(10).equals(new Integer(10))); : } : public static void main(String [] args) : { : } : } : A. Compile error