None of these objects are eligible for garbage collection.
Only the object referenced by booch is eligible for garbage collection.
Only the object referenced by snoog is eligible for garbage collection.
Only the object referenced by snooch is eligible for garbage collection.
The objects referenced by snooch and booch are eligible for garbage collection.
第1题:
以下是JAVA中正确的入口方法是? ()
第2题:
下列有关main()方法的签名正确的是哪些?()
第3题:
下面哪些选项是正确的main方法说明?()
第4题:
11.classA { 12. public void process() { System.out.print(”A “); } } 13. class B extends A { 14. public void process() throws RuntimeException { 15. super.process(); 16. if (true) throw new RuntimeException(); 17. System.out.print(“B”); }} 18. public static void main(String[] args) { 19. try { ((A)new B()).process(); } 20. catch (Exception e) { System.out.print(”Exception “); } 21. } What is the result?()
第5题:
下面哪些main方法可用于程序执行()
第6题:
Given: 11. static class A { 12. void process() throws Exception { throw new Exception(); } 13. } 14. static class B extends A { 15. void process() { System.out.println("B "); } 16. } 17. public static void main(String[] args) { 18. A a = new B(); 19. a.process(); 20. } What is the result? ()
第7题:
None of these objects are eligible for garbage collection.
Only the object referenced by booch is eligible for garbage collection.
Only the object referenced by snoog is eligible for garbage collection.
Only the object referenced by snooch is eligible for garbage collection.
The objects referenced by snooch and booch are eligible for garbage collection.
第8题:
public void main(String args[])
public void static main(String args[])
public static main(String[] argv)
final public static void main(String [] array)
public static void main(String args[])
第9题:
Exception
A Exception
A Exception B
A B Exception
Compilation fails because of an error in line 14.
Compilation fails because of an error in line 19.
第10题:
Compilation fails because of an error in line 19.
An exception is thrown at runtime.
B
Compilation fails because of an error in line 18.
Compilation fails because of an error in line 15.
The code runs with no output.
第11题:
public static void main(String[]args){…}
private static void main(String args[]){…}
public void main(String args[]){…}
public static void main(){…}
第12题:
public static void main(String[]args)
public static void main(String[]x)
public static void main(Stringargs[])
public void main(String[]args)
第13题:
Which declarations will allow a class to be started as a standalone program?()
第14题:
11. static class A { 12. void process() throws Exception { throw new Exception(); } 13. } 14. static class B extends A { 15. void process() { System.out.println(”B”); } 16. } 17. public static void main(String[] args) { 18. new B().process(); 19. } What is the result?()
第15题:
声明Java独立应用程序main()方法时,正确表达是()。
第16题:
11. class Snoochy { 12. Boochybooch; 13. public Snoochy() { booch = new Boochy(this); } 14. } 15. 16. class Boochy { 17. Snoochy snooch; 18. public Boochy(Snoochy s) { snooch = s; } 19. } And the statements: 21. public static void main(String[] args) { 22. Snoochy snoog = new Snoochy(); 23. snoog = null; 24. // more code here 25. } Which statement is true about the objects referenced by snoog, snooch, and booch immediately after line 23 executes?()
第17题:
11. static classA { 12. void process() throws Exception { throw new Exception(); } 13. } 14. static class B extends A { 15. void process() { System.out.println(”B “); } 16. } 17. public static void main(String[] args) { 18.A a=new B(); 19. a.process(); 20.} What is the result?()
第18题:
B
The code runs with no output.
An exception is thrown at runtime.
Compilation fails because of an error in line 15.
Compilation fails because of an error in line 18.
Compilation fails because of an error in line 19.
第19题:
public static void main(String[] args)
public static int main(String[] args)
public void main(String[] args)
public int main(String[] args)
第20题:
None of these objects are eligible for garbage collection.
Only the object referenced by booch is eligible for garbage collection.
Only the object referenced by snoog is eligible for garbage collection.
Only the object referenced by snooch is eligible for garbage collection.
The objects referenced by snooch and booch are eligible for garbage collection.
第21题:
public static void main(String[] args){}
public static void main(String args){}
public void main(String[] args){}
public static int main(String[] args){}
第22题:
B
The code runs with no output.
Compilation fails because of an error in line 12.
Compilation fails because of an error in line 15.
Compilation fails because of an error in line 18.
第23题:
public static void main(String[] args){}
public static void main(){}
public static void main(String args[]){}
public void static main(String[] args){}
第24题:
public main(String args[])
public static void main(String args[])
private static void main(String args[])
void main()