Read and understand the following program:
solve).Solve two standard (commercial) logic puzzles.
spiegel instead of speigel.
Be especially careful of this.
\+. Here's what you need to know about this operator:
\+E
will try to find variable bindings that will make E
true. If it fails to make E
true, no new bindings are formed; if it succeeds, then\+E will fail, and no new bindings
are formed.\+E
will never result in additional bindings!\+ works as you would expect when all variables are
completely instantiated (bound).There are two similar programs in this assignment, worth 50 points each. You earn full credit for each program that produces the correct solution, half credit for a program that appears to run but produces an incorrect solution.
How can you tell if your results are correct? Just manually check whether the solution satisfies all of the conditions of the problem! (Checking a solution is much easier than finding one.)
Although unlikely, we reserve the right to deduct points if your style is egregiously bad.
Midnight
Tuesday, September 8. Please zip
up and turn in three files to Canvas--your
two .pl files, along with a file containing the two solutions
(copy from the output area and paste them into a text file).
Also see the late policy, especially as it applies to this first assignment.