int count = 1; Token cur = firstToken; while (cur != lastToken) { ++count; cur = cur.next; }  numTokens = count;
  public void setLastToken(Token t) {    this.lastToken = t;    int count = 1;    Token cur = firstToken;    while (cur != lastToken) {      ++count;      cur = cur.next;    }    numTokens = count;  }