code: public String join( String separator, boolean stripQuotes ) {
        int len = size();
        StringBuffer sb = new StringBuffer();
  
        for( int i = 0; i < len; i += 1 ){
           if( i > 0 ){
              sb.append( separator );
           }
           String value = JSONUtils.valueToString( this.elements.get( i ) );
           sb.append( stripQuotes ? JSONUtils.stripQuotes( value ) : value );
        }
        return sb.toString();
     }
docs: Make a string from the contents of this JSONArray. The
  <code>separator</code> string is inserted between each element. Warning:
  This method assumes that the data structure is acyclical.
  
  @param separator A string that will be inserted between the elements.
  @return a string.
  @throws JSONException If the array contains an invalid number.