String objects are immutable, and String reference variables are not.
If you redirect a String reference to a new String, the old String can be lost.
The String class is final. String's methods can't be overridden.
String literals are strings that are specified using double quotes.
publicclass MainClass{
publicstaticvoid main(String[] argv){
String str = "text";
System.out.println(str);
}
}