How to convert an array to string in java?
Answers
Answered by
1
Using Arrays.toString() Method. Arrays.toString() returns a string with the content of the input array. ...
Using StringBuilder.append() Method. Let's use the StringBuilder.append() method to convert an Array to a String: ...
Using String.join() method.
Answered by
3
We can convert an Array into String by using Arrays class from java.util package.
It can used as follows:
Arrays.toString(array_name);
This method returns the Array in String format.
Similar questions