convert String from char arry code example
Example 1: char array to string
String string = String.valueOf(a);
Example 2: java string copy characters
public class Demo {
public static void main(String []args) {
char[] arr = { 'p', 'q', 'r', 's' };
String str = String.copyValueOf(arr, 1, 2);
System.out.println(str);
}
}