Solves equations and does other work with Cons and trees