搜题
章节测试答案
学历考试
继续教育
网课答案
网课答案全集
登录
注册
请在
下方输入
要搜索的题目:
搜 索
立 即 搜 题
有如下代码:String s1="hello";String s2="hello";则s1==s2的结果为true。
A:错
B:对
结果
代码
有如
发布时间:
2024-04-03 17:42:42
首页
网课答案全集
推荐参考答案
(
由 搜题小帮手 官方老师解答 )
联系客服
答案:
以下文字与答案无关
提示:有些试题内容 显示不完整,文字错误 或者 答案显示错误等问题,这是由于我们在扫描录入过程中 机器识别错误导致,人工逐条矫正总有遗漏,所以恳请 广大网友理解。
查看参考答案
相关试题
1.
有如下代码:String s1="hello";String s2="hello";则s1==s2的结果为true。选项: A:错 B:对
2.
有如下代码:String s1="hello";String s2="hello";则s1.equals(s2)的结果为false。选项: A:对 B:错
3.
有如下代码:String s1="hello";String s2="hello";则s1.equals(s2)的结果为false。 选项: A、对 B、错
4.
已知String s1="hello";String s2=new String("hello");则表达式s1==s2的结果是? 选项: A、true B、false
5.
下列代码的执行结果是( )。public class Test{public static void main(String args[]){String s1=new String(“Hello”);String s2=new String(“Hello”);System.out.println(s1==s2);System.out.println(s1.equals(s2));}}A、true falseB、true trueC、false trueD、false false
6.
中国大学MOOC: String s1,s2,s3;s1=Hello!;s2=Hello!;s3=new String(Hello!);则s1==s2;和s1==s3;的值为( )。
7.
阅读下面的代码,程序的运行结果是( )。class StringDemo{public static void main(String[] args){String s1 = “Hello”;String s2 = “Java”;show(s1,s2);System.out.println(s1+s2);}public static void show(String s1,String s2){s1 = s1 +“-”;s2 = s2 + s1;}}选项: A:Java B:Hello-Java C:Hello-JavaHello D:Hello-JavaHello-
8.
以下程序的输出为 ( ) string s1("hello"); string s2(“world”); string& rs = s1; rs = s2; cout<
9.
下列代码的执行结果是:( ) Public class Test5{ Public static void main(String args]){ String s1=new String("hello"); String s2=new String("hello"); System.out.print(s1==s2); System.out.print(","); System.out.println(s1.equals(s2)); } } 选项: A:true,false B:true,true C:false,true D:false,false
10.
下列代码段的执行结果是( )。 public class Test public static void main(String args[]) String s1=new String("hello"); String s2=new String"hello"); System.out.println(s1==s2); System.out.println(s1.equal(s2)); A.true falseB.true trueC.false trueD.false false
11.
下列代码段的执行结果是( )。 public class Test { public static void main(String args[ ]) { String s1= new String("hello"); String s2= new String("hello"); System.out.println(s1==s2); System.out.println(s1.equal(s2)); } }
12.
下面程序的运行结果是()public class Example { public static void main(String[] args) { String s1 = new String("Hello"); String s2 = new String("Hello"); System.out.print(s1 == s2); String s3 = "Hello"; String s4 = "Hello"; System.out.print(s3 == s4); s1 = s3; s2 = s4; System.out.print(s1 == s2); }}
13.
下列代码的执行结果是 public class StringTest{ public static void main(String args[]){ String s1= "hello"; String s2= "hello"; System.out.print(s1==s2); System.out.print(","); System.out.println(s1.equals(s2)); } }A.true,falseB.true,trueC.false,trueD.false,false
14.
以下代码共创建了几个对象?String s1=new String("hello");String s2=new String("hello");String s3=s1;String s4=s2; 选项: A:2; B:4; C:1; D:3
15.
以下程序段的输出结果为:____public class StringDemo {public static void main(String args[]){String s1,s2,s3;s1=new String("hello");s2=new String("hello");s3="hello";System.out.println(s1==s2);System.out.println(s1==s3);System.out.print (s1.equals(s2)+" "+s2.equals(s3));}
16.
下面程序的运行结果是( ) public class Test { public static void main(String[] args) { String s1 = new String("Hello"); String s2 = new String("Hello"); boolean b1 = s1.equals(s2); boolean b2 = s1 == s2; System.out.println(b1 + ", " + b2); }}选项: A:false, true; B:true, false; C: false, false; D: true, true
17.
有String s1=new String (“abc”); String s2=new String (“abc”);[br][/br] 则s1= =s2;的值为真(true)。
用户中心
登录
没有账号?
点我注册
热门标签
借入
圆场
闻声
大同
补缀
老马识途
放在第一位
腐败
房产家居
雪茄烟
登录 - 搜题小帮手
登录
立即注册
已购买搜题包,但忘记账号密码?
登录即同意
《服务协议》
及
《隐私政策》
注册 - 搜题小帮手
确认注册
立即登录
登录即同意
《服务协议》
及
《隐私政策》
购买搜题卡查看答案
购买前请仔细阅读
《购买须知》
体验
30天体验包
¥
5.99
无赠送,体验一下
查看100次答案
推荐
半年基础包
¥
9.99
畅享300次搜题
查看300次答案
随心用
超值包一年
¥
29.99
超值包,一万次搜题
查看10000次答案
月卡
月卡
¥
19.99
30天无限搜题
查看30天答案
请选择支付方式
已有帐号 点我登陆
微信支付
支付宝扫码
请输入您的手机号码:
点击支付即表示同意并接受了
《服务协议》
和
《购买须知》
填写手机号码系统自动为您注册
立即支付
我们不保证100%有您要找的试题及正确答案!请确保接受后再支付!
联系客服
找回账号密码
微信支付
订单号:
1111
遇到问题请
联系客服
恭喜您,购买搜题卡成功
系统为您生成的账号密码如下:
账号
密码
重要提示:
请勿将账号共享给其他人使用,违者账号将被封禁。
保存账号查看答案
请不要关闭本页面,支付完成后请点击【支付完成】按钮
支付完成
取消支付
遇到问题请联系
在线客服