       }
       env = newenv;
       form = tf_progn(forms,env);
-      TC = 1;
+      TC = TCstart;
       goto EVAL;
     }
 

    else if (c == 'r') fun = read();
    else if (c == '\r') { pfl(); printobject(fun); pln(); }
    else if (c == 'c') fun = cons(read(), fun);
    else if (!consp(fun)) pchar('!');
    else if (c == 'd') fun = cons(car(fun), edit(cdr(fun)));
    else if (c == 'a') fun = cons(edit(car(fun)), cdr(fun));
    else if (c == 'x') fun = cdr(fun);

  }
}

// Prettyprinter

const int ppindent = 2;
const int defaultppwidth = 80;
int ppwidth;

int atomwidth (object *obj) {
  if (obj == NULL) return 3;
  if (obj->type == NUMBER) {
    int w = 1;
    int n = obj->integer;
    if (n < 0) { n = -n; w++; }
    while (n >= 10) { n = n/10; w++; }
    return w;
  }
  if (obj->type == STRING) return stringlength(obj);
  int w = 0;
  char *s = name(obj);
  while (*s++) w++;
  return w;
}

boolean quoted (object *obj) {
  return (consp(obj) && (car(obj)->name == QUOTE) && consp(cdr(obj)) && (cddr(obj) == NULL));
}

int subwidth (object *obj, int w) {
  if (atom(obj)) return w - atomwidth(obj);
  if (quoted(obj)) return subwidthlist(car(cdr(obj)), w - 1);
  return subwidthlist(obj, w - 1);
}

int subwidthlist (object *form, int w) {
  while (form != NULL && w >= 0) {
    if (atom(form)) return w - (2 + atomwidth(form));
    w = subwidth(car(form), w - 1);
    form = cdr(form);
  }
  return w;
}

void superprint (object *form, int lm) {
  if (atom(form)) printobject(form);
  else if (quoted(form)) { pchar('\''); superprint(car(cdr(form)), lm + 1); }
  else if (subwidth(form, ppwidth - lm) >= 0) supersub(form, lm + ppindent, 0);
  else supersub(form, lm + ppindent, 1);
}

const int ppspecials = 8;
const char ppspecial[ppspecials] PROGMEM = { IF, SETQ, TEE, LET, LETSTAR, LAMBDA, WHEN, UNLESS };

void supersub (object *form, int lm, int super) {
  int special = 0, separate = 1;
  object *arg = car(form);
  if (symbolp(arg)) {
    int name = arg->name;
    if (name == DEFUN) special = 2;
    else for (int i=0; i<ppspecials; i++) {
      if (name == pgm_read_byte(&ppspecial[i])) { special = 1; break; }    
    } 
  }
  while (form != NULL) {
    if (atom(form)) { pfstring(F(" . ")); printobject(form); pchar(')'); return; }
    else if (separate) { pchar('('); separate = 0; }
    else if (special) { pchar(' '); special--; }
    else if (!super) pchar(' ');
    else { pln(); indent(lm); }
    superprint(car(form), lm);
    form = cdr(form);   
  }
  pchar(')'); return;
}

object *fn_pprint (object *args, object *env) {
  (void) env;
  pln();
  superprint(first(args), 0);
  return symbol(NOTHING);
}

// Insert your own function definitions here

// Built-in procedure names - stored in PROGMEM

const char string0[] PROGMEM = "symbols";
const char string1[] PROGMEM = "nil";
const char string2[] PROGMEM = "t";
const char string3[] PROGMEM = "nothing";
const char string4[] PROGMEM = "string";
const char string5[] PROGMEM = "&rest";
const char string6[] PROGMEM = "lambda";
const char string7[] PROGMEM = "let";
const char string8[] PROGMEM = "let*";
const char string9[] PROGMEM = "closure";
const char string10[] PROGMEM = "special_forms";
const char string11[] PROGMEM = "quote";
const char string12[] PROGMEM = "defun";
const char string13[] PROGMEM = "defvar";
const char string14[] PROGMEM = "setq";
const char string15[] PROGMEM = "loop";
const char string16[] PROGMEM = "push";
const char string17[] PROGMEM = "pop";
const char string18[] PROGMEM = "incf";
const char string19[] PROGMEM = "decf";
const char string20[] PROGMEM = "setf";
const char string21[] PROGMEM = "dolist";
const char string22[] PROGMEM = "dotimes";
const char string23[] PROGMEM = "trace";
const char string24[] PROGMEM = "untrace";
const char string25[] PROGMEM = "for-millis";
const char string26[] PROGMEM = "with-i2c";
const char string27[] PROGMEM = "with-spi";
const char string28[] PROGMEM = "tail_forms";
const char string29[] PROGMEM = "progn";
const char string30[] PROGMEM = "return";
const char string31[] PROGMEM = "if";
const char string32[] PROGMEM = "cond";
const char string33[] PROGMEM = "when";
const char string34[] PROGMEM = "unless";
const char string35[] PROGMEM = "and";
const char string36[] PROGMEM = "or";
const char string37[] PROGMEM = "functions";
const char string38[] PROGMEM = "not";
const char string39[] PROGMEM = "null";
const char string40[] PROGMEM = "cons";
const char string41[] PROGMEM = "atom";
const char string42[] PROGMEM = "listp";
const char string43[] PROGMEM = "consp";
const char string44[] PROGMEM = "numberp";
const char string45[] PROGMEM = "symbolp";
const char string46[] PROGMEM = "streamp";
const char string47[] PROGMEM = "eq";
const char string48[] PROGMEM = "car";
const char string49[] PROGMEM = "first";
const char string50[] PROGMEM = "cdr";
const char string51[] PROGMEM = "rest";
const char string52[] PROGMEM = "caar";
const char string53[] PROGMEM = "cadr";
const char string54[] PROGMEM = "second";
const char string55[] PROGMEM = "cdar";
const char string56[] PROGMEM = "cddr";
const char string57[] PROGMEM = "caaar";
const char string58[] PROGMEM = "caadr";
const char string59[] PROGMEM = "cadar";
const char string60[] PROGMEM = "caddr";
const char string61[] PROGMEM = "third";
const char string62[] PROGMEM = "cdaar";
const char string63[] PROGMEM = "cdadr";
const char string64[] PROGMEM = "cddar";
const char string65[] PROGMEM = "cdddr";
const char string66[] PROGMEM = "length";
const char string67[] PROGMEM = "list";
const char string68[] PROGMEM = "reverse";
const char string69[] PROGMEM = "nth";
const char string70[] PROGMEM = "assoc";
const char string71[] PROGMEM = "member";
const char string72[] PROGMEM = "apply";
const char string73[] PROGMEM = "funcall";
const char string74[] PROGMEM = "append";
const char string75[] PROGMEM = "mapc";
const char string76[] PROGMEM = "mapcar";
const char string77[] PROGMEM = "+";
const char string78[] PROGMEM = "-";
const char string79[] PROGMEM = "*";
const char string80[] PROGMEM = "/";
const char string81[] PROGMEM = "mod";
const char string82[] PROGMEM = "1+";
const char string83[] PROGMEM = "1-";
const char string84[] PROGMEM = "abs";
const char string85[] PROGMEM = "random";
const char string86[] PROGMEM = "max";
const char string87[] PROGMEM = "min";
const char string88[] PROGMEM = "=";
const char string89[] PROGMEM = "<";
const char string90[] PROGMEM = "<=";
const char string91[] PROGMEM = ">";
const char string92[] PROGMEM = ">=";
const char string93[] PROGMEM = "/=";
const char string94[] PROGMEM = "plusp";
const char string95[] PROGMEM = "minusp";
const char string96[] PROGMEM = "zerop";
const char string97[] PROGMEM = "oddp";
const char string98[] PROGMEM = "evenp";
const char string99[] PROGMEM = "stringp";
const char string100[] PROGMEM = "string=";
const char string101[] PROGMEM = "concatenate";
const char string102[] PROGMEM = "subseq";
const char string103[] PROGMEM = "logand";
const char string104[] PROGMEM = "logior";
const char string105[] PROGMEM = "logxor";
const char string106[] PROGMEM = "lognot";
const char string107[] PROGMEM = "ash";
const char string108[] PROGMEM = "logbitp";
const char string109[] PROGMEM = "eval";
const char string110[] PROGMEM = "globals";
const char string111[] PROGMEM = "locals";
const char string112[] PROGMEM = "makunbound";
const char string113[] PROGMEM = "break";
const char string114[] PROGMEM = "read";
const char string115[] PROGMEM = "prin1";
const char string116[] PROGMEM = "print";
const char string117[] PROGMEM = "princ";
const char string118[] PROGMEM = "terpri";
const char string119[] PROGMEM = "read-line";
const char string120[] PROGMEM = "read-byte";
const char string121[] PROGMEM = "write-byte";
const char string122[] PROGMEM = "restart-i2c";
const char string123[] PROGMEM = "gc";
const char string124[] PROGMEM = "room";
const char string125[] PROGMEM = "save-image";
const char string126[] PROGMEM = "load-image";
const char string127[] PROGMEM = "cls";
const char string128[] PROGMEM = "pinmode";
const char string129[] PROGMEM = "digitalread";
const char string130[] PROGMEM = "digitalwrite";
const char string131[] PROGMEM = "analogread";
const char string132[] PROGMEM = "analogwrite";
const char string133[] PROGMEM = "delay";
const char string134[] PROGMEM = "millis";
const char string135[] PROGMEM = "note";
const char string136[] PROGMEM = "edit";
const char string137[] PROGMEM = "pprint";

const tbl_entry_t lookup_table[] PROGMEM = {
  { string0, NULL, NIL, NIL },
