Updated prove.py for lines.

Many bugs are left.