Java tutorial
//package com.java2s; public class Main { public static String makeQuestionmarks(int n) { if (n <= 0) { return ""; } StringBuilder builder = new StringBuilder("?"); for (int i = 1; i < n; i++) { builder.append(",?"); } return builder.toString(); } }