true
false
0
1
第1题:
语句"Hell0".equals("hell0");的正确执行结果是( )。
A.true
B.false
C.0
D.1
第2题:
A.true
B.false
C.1
D.0
第3题:
假设有以下代码: String s="hello"; String t="hello"; char c[ ]={'h','e','l','l','o'}; 下列选项中,返回false的语句是______。
A.s.equals(t);
B.t.equals(c);
C.s==t;
D.t.equals(new String("hello"));
第4题:
给出下列的代码,则以下哪个选项返回true? String s="hello"; String t="hello"; char c []= {'h','e','1','1','o'};A)s.equals(t);
A.t. equals(
B.;
C.s==t;
D.t==c;
第5题:
A.s.equals(t);
B.t.equals(c);
C.s==t;
D.t.equals(newString("hello"));
E.t==c;
第6题:
A.true
B.false
C.1
D.0
E.hello
第7题:
publicclassClassA{publicintgetValue(){intvalue=0;booleansetting=true;Stringtitle=”Hello”;(value||(setting&&title==Hello”)){return1;}(value==1&title.equals(”Hello”)){return2;}}}And:ClassAa=newClassA();a.getValue();Whatistheresult?()
A.1
B.2
C.Compilationfails.
D.Thecoderunswithnooutput.
E.Anexceptionisthrownatruntime.
第8题:
语句“Hello”. equals(“hello”);的正确执行结果是______。
A) true
B) false
C) 0
D) 1
A.
B.
C.
D.
第9题:
下列代码的执行结果是()。publicclasstest5{publicstaticvoidmain(Stringargs[]){Strings1=newString("hello");Strings2=newString("hello");System.out.prim(s1==s2);System.out.print(",");System.out.println(s1.equals(s2));}
A.true,false
B.true,true
C.false,true
D.false,false
第10题:
语句”Hello”.equals(”hello”);的正确执行结果是( )。
A.true
B.false
C.0
D.1