Lookahead that doesn't quite work
Finally fixed floating point bug.

Also improved performance.