Java tutorial
//package com.java2s; import java.util.List; public class Main { public static String asCSV(List<String> strings) { StringBuilder s = new StringBuilder(); boolean first = true; for (String n : strings) { if (!first) s.append(","); s.append(n); first = false; } return s.toString(); } }