public static String arrayString(int[] items) {
        StringBuilder sB = new StringBuilder("i[");
        boolean isFirst = true;
        for (int item : items) {
            if (isFirst) {
                isFirst = false;
            } else {
                sB.append(" ");
            }
            sB.append(item);
        }
        return sB.append("]").toString();
    }
public static String arrayString ( int [ ] items ) { StringBuilder sB = new StringBuilder ( "i[" ) ; boolean isFirst = true ; for ( int item : items ) { if ( isFirst ) { isFirst = false ; } else { sB . append ( " " ) ; } sB . append ( item ) ; } return sB . append ( "]" ) . toString ( ) ; }
TODO: We need one of these for each type of primitive for pretty-printing without commas.