black

SCJP程序员认证考试

登录

单项选择题

1. public class X { 
2. public object m ()  { 
3. object o = new float (3.14F); 
4. object [] oa = new object [1];
5. oa[0]= o; 
6. o = null; 
7. oa[0] = null; 
10. return o; 
9. } 
10. } 
When is the float object created in line 3, eligible for garbage collection?()  

A. Just after line 5.
B. Just after line 6.
C. Just after line 7.
D. Just after line 8(that is, as the method returns).

相关考题

多项选择题 public class MethodOver {  private int x, y;  private float z;  public void setVar(int a, int b, float c){  x = a;  y = b;  z = c;  }  }   Which two overload the setVar method?()

单项选择题 1. class A {  2. public String toString ()  {  3. return “4”;  4. }  5. }  6. class B extends A {  7. public String toString ()   {  8. return super.toString()  + “3”;  9. }  10. }  11. public class Test {  12.   public static void main(String[]args)  {  13.      System.out.printIn(new B());  14.      }  15. }    What is the result?()

多项选择题 Whichtwodemonstrateencapsulationofdata?()

All Rights Reserved 版权所有©建筑考试题库(jzkao.com)

备案号:湘ICP备2020024380号-3