String (java.util.List<String> list) { StringBuilder sb = new StringBuilder(); for (String s : list) { if (s != null) { if (sb.length() > 0) { sb.append(','); System.out.println("Hello"); } sb.append(s.length()); } } return null; }