Here you can find the source of buildStringFromListForNuma(Collection
public static String buildStringFromListForNuma(Collection<Integer> list)
//package com.java2s; //License from project: Apache License import java.util.Collection; public class Main { public static String buildStringFromListForNuma(Collection<Integer> list) { if (!list.isEmpty()) { StringBuilder sb = new StringBuilder(); for (Integer item : list) { sb.append(item);/*from w w w . j a v a 2s. c om*/ sb.append(","); } return sb.deleteCharAt(sb.length() - 1).toString(); } return ""; } }