CSE 341 -- Programming Languages

Spring 1999

Department of Computer Science and Engineering, University of Washington

Steve Tanimoto (instructor) and Jeremy Baer (teaching assistant).

Assignment H1

Version 1.00 of May 10.  Subject to change.

Horn Clause Programming 

Due date and time: Monday, May 17, 1999, at 12:30 (at the beginning of class).

Turn in this assignment as a hardcopy printout. 


 

Title: Horn Clause Programming.

Purposes:  To gain an understanding of the basic mechanism in a logic-programming interpreter and to experience the process of formulating a program for logic-programming language.

Instructions:

Make up a set of 2 to 5 rules and 5 to 10 facts for one of the topics below.  Formulate your rules and facts as a logic program.  Pose a query that demonstrates the use of all your rules and some of your facts.  Run the program using the Mock Prolog interpreter.  Print out the Lisp representation of your rules and facts, plus a run showing the query and results for your example query.

Topics: selecting a course at UW.  Choosing a sporting activity or a ski resort.  Choosing a restaurant in Seattle.

Teamwork:  Do your work individually on this assignment.

Resources:  Here is a summary of Horn-clause programming.