Java String
String Tokenizer class
The java.util.StringTokenizer class allows you to break a string into tokens. It is simple way to break string. It doesn’t provide the facility to differentiate…
toString method
If you want to represent any object as a string, toString() method comes into existence. The toString() method returns the string representation of the object….
Create Immutable class
There are many immutable classes like String, Boolean, Byte, Short, Integer, Long, Float, Double etc. In short, all the wrapper classes and String class is…
StringBuffer vs StringBuilder
There are many differences between StringBuffer and StringBuilder. A list of differences between StringBuffer and StringBuilder are given below: No. StringBuffer StringBuilder 1) StringBuffer is…
String vs StringBuffer
There are many differences between String and StringBuffer. A list of differences between String and StringBuffer are given below: No. String StringBuffer 1) String class…
StringBuilder class
Java StringBuilder class is used to create mutable (modifiable) string. The Java StringBuilder class is same as StringBuffer class except that it is non-synchronized. It…
StringBuffer class
Java StringBuffer class is used to created mutable (modifiable) string. The StringBuffer class in java is same as String class except it is mutable i.e….
methods of String class methods
The java.lang.String class provides a lot of methods to work on string. By the help of these methods, we can perform operations on string such…
String Concatenation
In java, string concatenation forms a new string that is the combination of multiple strings. There are two ways to concat string in java: By…