publicclassTest{publicstaticvoidmain(Stringargs[]){classFoo{publicinti=3;}Objecto=(Object)newFoo();Foofoo=(Foo)o;System.out.println(i=+foo.i);}}Whatistheresult?()
A. i=3
B. Compilationfails.
C. AClassCastExceptionisthrownatline6.
D. AClassCastExceptionisthrownatline7.
publicclassForBar{publicstaticvoidmain(Stringargs){inti=0,j=5;tp:for(;;){i++;for(;;)if(i>--j)breaktp;}system.out.printIn(i=”+i+,j=+j);}}Whatistheresult?()
A. Theprogramrunsandprints“i=1,j=0”
B. Theprogramrunsandprints“i=1,j=4”
C. Theprogramrunsandprints“i=3,j=4”
D. Theprogramrunsandprints“i=3,j=0”
E. Anerroratline4causescompilationtofail.
F. Anerroratline7causescompilationtofail.
哪项是正方立论的根基:()
A. 高薪捆绑了一种道德承诺
B. 养廉是一个个体主观能动性的表现
C. 高薪是客观刺激或客观激励
D. 不能意味着非主要动力
Whatallowstheprogrammertodestroyanobjectx?()
A. x.delete()
B. x.finalize()
C. Runtime.getRuntime().gc()
D. Explicitlysettingtheobject’sreferencetonull.
Ensuringtherearenoreferencestotheobject.
F. Onlythegarbagecollectionsystemcandestroyanobject.