String s1 = “abc”;
String s2 = new String(“abc”);
System.out.println(s1==s2);
String s3 = “你好吗”;
String s4 =”你”;
String s5 =”好吗”;
System.out.println(s3==(s4+s5))
String s1 = “abc”;
String s2 = new String(“abc”);
System.out.println(s1==s2);
String s3 = “你好吗”;
String s4 =”你”+ ”好吗”;
System.out.println(s3==s4))
欢迎光临 黑马程序员技术交流社区 (http://bbs.itheima.com/) | 黑马程序员IT技术论坛 X3.2 |