-->
当前位置:首页 > 题库

单选题:What will happen if you try to compile and run the following cod

Luz5年前 (2021-05-10)题库630
What will happen if you try to compile and run the following code?@[C](2)
```Java
public class Q {
public static void main(String argv[]){
int anar[]=new int[5];
System.out.println(anar[0]);
}
}
```

A. Error: anar is referenced before it is initialized
B. null
C. 0
D. 5




A.Error: anar is referenced before it is initialized
B.null
C.0
D.5


答案:C