View Questions and Answers by Category
Please explain me the working of intern().
You can compare String objects and string characters by using the method intern(). It is much faster than equals() method.
For more information, visit the following link:
String intern() method