Added a function to guess that a given Program is a solution to a particular problem.