Mention the purpose and syntax of valueOf() method.
3 Likes
The valueOf() method returns the string representation of the argument.Syntax:String.valueOf(data)
String.valueOf(data)
Here, data can be of various types like char, boolean, int, long, float, double or char array.
Answered By
1 Like
Differentiate between equals() and compareTo().
Mention the purpose and syntax of compareToIgnore() method.
Mention the purpose and syntax of substring() method.
Differentiate between equals() and == .