private void toString(StringBuffer result) { int size = size(); result.append('('); for (int i = 0; i < size; i++) { if (i > 0) result.append(' '); Sexp curr = get(i); if (curr instanceof Symbol) result.append(curr); else ((SexpList)curr).toString(result); } result.append(')');
public String toString() { StringBuffer result = new StringBuffer(5 * size()); toString(result); return result.toString();
  private void toString(StringBuffer result) {    int size = size();    result.append('(');    for (int i = 0; i < size; i++) {      if (i > 0)	result.append(' ');      Sexp curr = get(i);      if (curr instanceof Symbol)	result.append(curr);      else	((SexpList)curr).toString(result);    }    result.append(')');  }