Below is a script file captured while running a sample Prolog session. The text appearing in red was typed by the user -- that in black was output by the system.

 

fleck@monsoon [101]% prolog

SICStus 3.7.1 (HP-UX-B.10.20-9000/780): Tue Oct 06 13:43:46 METDST 1998

Licensed to cs.uiowa.edu

| ?- consult(kennedy).

{consulting /tmp_mnt/group/class/c002/kennedy...}

{/tmp_mnt/group/class/c002/kennedy consulted, 40 msec 10728 bytes}

yes

| ?- consult(familial).

{consulting /tmp_mnt/group/class/c002/familial...}

{/tmp_mnt/group/class/c002/familial consulted, 10 msec 2184 bytes}

yes

| ?- brotherOf(caroline_Kennedy,X).

X = john_KennedyJr ? ;

X = patrick_Kennedy ? ;

no

| ?- motherOf(john_KennedyJr,M).

M = jacqueline_Bouvier ? ;

no

| ?- brotherOf(X,john_KennedyJr).

X = caroline_Kennedy ? ;

X = patrick_Kennedy ?

yes

| ?- halt.

fleck@monsoon [102]% exit

exit

script done on Tue Sep 18 14:44:28 2001