fixed the increments in tokensToProgram (pre- and postfix increments have different semantics)
merged