Java tutorial
//package com.java2s; public class Main { public static String joinArray(int[] arr, String seperator) { StringBuilder sb = new StringBuilder(); for (Integer i : arr) { sb.append(i).append(seperator); } if (sb.length() > 0) { return sb.subSequence(0, sb.length() - seperator.length()).toString(); } return sb.toString(); } }