Computer Applications

Mention the purpose and syntax of valueOf() method.

Java String Handling

3 Likes

Answer

The valueOf() method returns the string representation of the argument.
Syntax:
String.valueOf(data)

Here, data can be of various types like char, boolean, int, long, float, double or char array.

Answered By

1 Like


Related Questions