Compilation fails.
An exception is thrown at runtime.
The variable first is set to null.
The variable first is set to elements[0].
第1题:
A.String regex="";
B.String regex=" .";
C.String regex=".*";
D.String regex="\\s";
E.String regex="\\.\\s*";
F.String regex="\\w[\.]+";
第2题:
Given:Andthefollowingfivefragments:publicstaticvoidmain(String...a){publicstaticvoidmain(String.*a){publicstaticvoidmain(String...a){publicstaticvoidmain(String[]...a){publicstaticvoidmain(String...[]a){Howmanyofthecodefragments,insertedindependentlyatline2,compile?()
A.0
B.1
C.2
D.3
E.4
第3题:
A.Compilation fails.
B.An exception is thrown at runtime.
C.The variable first is set to null.
D.The variable first is set to elements[0].
第4题:
Given that c is a reference to a valid java.io.Console object, which two code fragments read a line of text from the console?()
第5题:
String[] elements = { “for”, “tea”, “too” }; String first = (elements.length > 0)? elements[0] null; What is the result?()
第6题:
A.Compilationfails.
B.Anexceptionisthrownatruntime.
C.Thevariablefirstissettonull.
D.Thevariablefirstissettoelements[0].
第7题:
floatf;Strings;现需要把float转化为String,正确的语句是()
第8题:
A.Compilationfails.
B.Anexceptionisthrownatruntime.
C.Thevariablefirstissettonull.
D.Thevariablefirstissettoelements[0].
第9题:
Given: 11.String test = "a1b2c3"; 12.String[] tokens = test.split("//d"); 13.for(String s: tokens) System.out.print(s + " "); What is the result?()
第10题:
有声明语句:delegate void TimeDelegate(string s),则以下语句可以和委托TimeDelegate绑定的方法是()