当前位置:七七学习网文档大全求职指南求职笔试面试笔试题目java软件开发工程师笔试题» 正文

java软件开发工程师笔试题

[10-10 21:21:19]   来源:http://www.77xue.com  笔试题目   阅读:8666
概要:选择题1:In the following code, which is the earliest statement, where the object originally held in e, may be garbage collected:1.public class Test {2. public static void main (String args []) {3. Employee e = new Employee("Bob", 48);4. e.calculatePay();5. System.out.println(e.printDetails());6. e = null;7. e = new Employee("Denise", 36);8. e.calculatePay();9. System.out.println(e.printDetails());10. }11.}Only One:In the followin
java软件开发工程师笔试题,标签:驾照笔试题目,腾讯笔试题目,http://www.77xue.com

  选择题

  1:

  In the following code, which is the earliest statement, where the object originally held in e, may be garbage collected:

  1.public class Test {

  2. public static void main (String args []) {

  3. Employee e = new Employee("Bob", 48);

  4. e.calculatePay();

  5. System.out.println(e.printDetails());

  6. e = null;

  7. e = new Employee("Denise", 36);

  8. e.calculatePay();

  9. System.out.println(e.printDetails());

  10. }

  11.}

  Only One:

  In the following code, which is the earliest statement, where the object originally held in e, may be garbage collected:

  1.public class Test {

  2. public static void main (String args []) {

  3. Employee e = new Employee("Bob", 48);

  4. e.calculatePay();

  5. System.out.println(e.printDetails());

  6. e = null;

  7. e = new Employee("Denise", 36);

  8. e.calculatePay();

  9. System.out.println(e.printDetails());

  10. }

  11.}

  Only One:

  A.Line 10

  B.Line 11

  C.Line 7

  D.Line 8

  2:Exhibit :

  1. public class test (

  2. private static int j = 0;

  3.

  4. private static boolean methodB(int k) (

  5. j += k;

  6. return true;

  6. )

www.77xue.com哦

  7.

  8. public static void methodA(int i) {

  9. boolean b:

  10. b = i < 10 | methodB (4);

  11. b = i < 10 || methodB (8);

  12. )

  13.

  14. public static void main (String args[] } (

  15. methodA (0);

  16. system.out.printIn(j);

  17. )

  18. )

  What is the result?

  A.The program prints “0”

  B.The program prints “4”

  C.The program prints “8”

  D.The program prints “12”

  3:What is written to the standard output given the following statement:System.out.println(4|7);

  Select the right answer:

  A.4

  B.5

  C.6

  D.7

  4:

  Select valid identifier of Java:

  Select valid identifier of Java:

  A.%passwd

  B.3d_game

  C.$charge

  D.this

  5:设有变量说明语句int a=1,b=0;

  则执行以下程序段的输出结果为( )。

  switch (a)

  {

  case 1:

  switch (b)

  {

  case 0:printf("**0**");break;

  case 1:printf("**1**");break;

  }

  case 2:printf("**2**");break;

  }

  printf(" ");

  A.**0**

  B.**0****2**

  C.**0****1****2**

  D.有语法错误

  6:In the following pieces of code, which one will compile without any error?

  A.StringBuffer sb1 = "abcd";

  B.Boolean b = new Boolean("abcd");

  C.C: byte b = 255;

  D.float fl = 1.2;

  7:

  What is the result when you compile and run the following code?

[1] [2] [3] [4]  下一页


Tag:笔试题目驾照笔试题目,腾讯笔试题目求职指南 - 求职笔试面试 - 笔试题目
联系我们 | 网站地图 | 范文大全 | 管理知识 | 教学教育 | 作文大全 | 语句好词
Copyright http://www.77xue.com--(七七学习网) All Right Reserved.
1 2 3 4 5 6 7 8 9 10