字符串的问题
String str = "abc"; 和 String str1 = new String("abc");的区别
不要告诉我第二个要用到构造函数,这个我知道,还有木有其他的区别



程序代码: String str1="abc";
String str2=new String("abc");
String str3=str2;
if(str1==str2){//第一个if语句
System.out.println("true");
}else {
System.out.println("false");
}
if(str2==str3){//第二个if语句
System.out.println("true");
}else {
System.out.println("false");
}
if(str1.equals(str2)){////第三个if语句。str1和str2进行内容的比较是一样的,返回true
System.out.println("true");
}else {
System.out.println("false");
}
}