大数据基础技能试题及答案

上传人:s9****2 文档编号:500139346 上传时间:2022-08-19 格式:DOC 页数:19 大小:98.51KB
返回 下载 相关 举报
大数据基础技能试题及答案_第1页
第1页 / 共19页
大数据基础技能试题及答案_第2页
第2页 / 共19页
大数据基础技能试题及答案_第3页
第3页 / 共19页
大数据基础技能试题及答案_第4页
第4页 / 共19页
大数据基础技能试题及答案_第5页
第5页 / 共19页
点击查看更多>>
资源描述

《大数据基础技能试题及答案》由会员分享,可在线阅读,更多相关《大数据基础技能试题及答案(19页珍藏版)》请在金锄头文库上搜索。

1、Java基础1. Which of the following will compile correctly?A) float f=10f;B) float f=10.1;C) float f=10.1f;D) byte b=10b;2. Which declarations of identifiers are legal A. $persons B. TwoUsers C. *point D. this E. _endline3. Which statement of assigning a long type variable to a hexadecimal value is corr

2、ect A. long number = 345L;B. long number = 0345;C. long number = 0345L;D. long number = 0x345L 4. Which of the following fragments might cause errors A. String s = Gone with the wind;String t = good ;String k = s + t;B. String s = Gone with the wind;String t;t = s3 + one;C. String s = Gone with the

3、wind;String standard = s.toUpperCase();D. String s = home directory;String t = s - directory;5. Which are syntactically valid statement at/ point x class Person private int a;public int change(int m) return m; public class Teacher extends Person public int b;public static void main(String arg)Person

4、 p = new Person();Teacher t = new Teacher();int i;/ point xA. i = m;B. i = b;C. i = p.a;D. i = p.change(30);E. i = t.b. 6. Which layout manager is used when the frame is resized the buttonss position in the Frame might be changed A. BorderLayoutB. FlowLayoutC. CardLayoutD. GridLayout 7. Given the fo

5、llowing code fragment:1) public void create() 2 Vector myVect;3 myVect = new Vector(); 4 Which of the following statements are true A. The declaration on line 2 does not allocate memory space for the variable myVect.B. The declaration on line 2 allocates memory space for a reference to a Vector obje

6、ct.C. The statement on line 2 creates an object of class Vector.D. The statement on line 3 creates an object of class Vector.E. The statement on line 3 allocates memory space for an object of class Vector 8. Which of the following answer is correct to express the value 8 in octal number A. 010B. 0x1

7、0C. 08D. 0x8 9. Which are not Java keywords A. TRUEB. sizeofC. constD. superE. void 10. Which of the following statements are true A. The equals() method determines if reference values refer to the same object.B. The = operator determines if the contents and type of two separate objects match.C. The

8、 equals() method returns true only when the contents of two objects match.D. The class File overrides equals() to return true if the contents and type of two separate objects match. 11. Which statements about inheritance are true A. In Java programming language only allows single inheritance. B. In

9、Java programming language allows a class to implement only one interface.C. In Java programming language a class cannot extend a class and implement a interface together.D. In Java programming language single inheritance makes code more reliable. 12. 1) class Person 2 public void printValue(int i, i

10、nt j) /*/ 3 public void printValue(int i)/*.*/ 4 5) public class Teacher extends Person 6 public void printValue() /*.*/ 7 public void printValue(int i) /*.*/8 public static void main(String args)9 Person t = new Teacher();10 t.printValue(10);11 12 Which method will the statement on line 10 call A.

11、on line 2B. on line 3C. on line 6D. on line 7 13. Which are not Java primitive types A. shortB. BooleanC. unitD. float 14、The method resume() is responsible for resuming which threads execution A. The thread which is stopped by calling method stop()B. The thread which is stopped by calling method sl

12、eep()C. The thread which is stopped by calling method wait()D. The thread which is stopped by calling method suspend()15. Which of the following range of int is correct A. -27 27-1 B. 0 232-1 C. -215 215-1 D. -231 231-1 16. Which keyword should be used to enable interaction with the lock of an objec

13、t The flag allows exclusive access to that object. A. transientB. synchronizedC. serializeD. static 17. Which is the return type of the method main() A. intB. voidC. booleanD. static 18. Given the following code:if (x0) System.out.println(first); else if (x-3) System.out.println(second); else System

14、.out.println(third); Which range of x value would print the string second A. x 0B. x -3C. x = -3D. x -3 19、Which of the following answer is correct to express the value 10 in hexadecimal number A. 0xAB. 0x16C. 0AD. 016 20. Which statements about the garbage collection are true A. The program developer must create a thread to be responsible for free the memory.B. The garbage collection will check for and free memory no longer needed.C. The garbage collection allow the program developer to explicity and immediately free the memory.D. The ga

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 高等教育 > 习题/试题

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号