QUESTION 17자격증/OCJP_ExamC2018. 7. 21. 18:52
Table of Contents
반응형
QUESTION 17Given:11. public static void main(String[] args) {12. Object obj = new int[] { 1, 2, 3 };13. int[] someArray = (int[])obj;14. for (int i : someArray)System.out.print(i + " ");15. }What is the result?A. 1 2 3B. Compilation fails because of an error in line 12.C. Compilation fails because of an error in line 13.D. Compilation fails because of an error in line 14.E. A ClassCastException is thrown at runtime.Solution : A
반응형
'자격증 > OCJP_ExamC' 카테고리의 다른 글
QUESTION 19 (0) | 2018.07.24 |
---|---|
QUESTION 18 (0) | 2018.07.24 |
QUESTION 16 (0) | 2018.07.21 |
QUESTION 15 (0) | 2018.07.21 |
QUESTION 14 (0) | 2018.07.21 |
@IT grow. :: IT grow.
#IT #먹방 #전자기기 #일상
#개발 #일상