Here you can find the source of merge(String[] strArray)
public static String merge(String[] strArray)
//package com.java2s; //License from project: Open Source License public class Main { public static String merge(String[] strArray) { return merge(strArray, ' '); }/*from ww w. j a v a 2 s . com*/ public static String merge(String[] strArray, char separator) { String retObj = null; if (strArray != null && strArray.length > 0) { retObj = ""; for (String str : strArray) { retObj += str + separator; } retObj = retObj.substring(0, retObj.length() - 1); // remove final separator character } return retObj; } }