单项选择题
A. Just after line 13.
B. Just after line 14.
C. Never in this method.
D. Just after line 15 (that is, as the method returns).
填空题 1.publicclassTest{2.publicstaticStringoutput=””;3.4.publicstaticvoidfoo(inti){5.try{6.if(i==1){7.thrownewException();8.}9.output+=“1”;10.}11.catch(Exceptione){12.output+=“2”;13.return;14.}15.finally{16.output+=“3”;17.}18.output+=“4”;19.}20.21.publicstaticvoidmain(Stringargs[]){22.foo(0);23.foo(1);24.25.}26.}Whatisthevalueofthevariableoutputatline23?()
单项选择题 class Super { public Integer getLenght() { return new Integer(4); } } public class Sub extends Super { public Long GetLenght() { return new Long(5); } public static void main(String[] args) { Super sooper = new Super(); Sub sub = new Sub(); System.out.println( sooper.getLenght().toString() + “,” + sub.getLenght().toString() ); } } What is the output?()
单项选择题 1.packagefoo;2.3.importjava.util.Vector;4.5.protectedclassMyVectorVector{6.initi=1;7.publicMyVector(){8.i=2;9.}10.}11.12.publicclassMyNewVectorextendsMyVector{13.publicMyNewVector(){14.i=4;15.}16.publicstaticvoidmain(Stringargs[]){17.MyVectorv=newMyNewVector();18.}19.}Whatistheresult?()