java convert a char array to string code example
Example 1: java string to char array
String str = "example";
char[] ch = str.toCharArray();
Example 2: char array to string java
char[] a = {'h', 'e', 'l', 'l', 'o', ' ', 'w', 'o', 'r', 'l', 'd'};
String str = new String(a);