Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

char array to string in java


      // Method 1: Using String object
      char[] ch = {'g', 'o', 'o', 'd', ' ', 'm', 'o', 'r', 'n', 'i', 'n', 'g'};
      String str = new String(ch);
      System.out.println(str);
 
Source by beginnersbook.com #
 
PREVIOUS NEXT
Tagged: #char #array #string #java
ADD COMMENT
Topic
Name
5+2 =