Here you can find the source of implode(String glue, String... parts)
public static String implode(String glue, String... parts)
//package com.java2s; // The license under which this software is released can be accessed at: public class Main { public static String implode(String glue, String... parts) { if ((glue == null) || (parts.length <= 0)) { return ""; }// w w w . ja v a 2 s . c o m String string = parts[0]; for (int i = 1; i < parts.length; i++) { string += glue + parts[i]; } return string; } }