String str = new String("javaTrain") ; /*new object1 in heap memory */
System.out.println(str == str.substring(0) ) ==> return true ??
why the result is true ?
str.substring(0) ==> /*new object2 in heap memory */
why objet1 and object2 are equals ?