Learning Module 18 — Prolog

Why this is important: Prolog is a strange language, even by our standards. But it is amazing for solving certain kinds of problems. Had you only learned C++ you could be successful as a computer scientist, but you would still miss out on a world of possibilities if you did not see languages such as these.

Oh, and MP 6? You can solve it in Prolog in about 15 minutes. Not that we’d let you do that for this class, but one day you may have a similar problem and remember there was an easier way….

Outcomes

  • 18.1 – Write a Prolog predicate that processes a list. (4 points)
  • 18.2 – Write a Prolog predicate that searches a graph-like structure. (4 points)
  • 18.3 – Show how to use the cut operator to limit unwanted backtracking. (2 points)
Previous
Next