Beezle Elite Member
Number of posts : 547 Age : 34 Mood : Points : 253 Registration date : 2008-03-02
Character sheet Weapon: Chakrams Class: Ninja HP: (50/50)
| Subject: Prolog Exercise 2 Tue Oct 19, 2010 7:41 pm | |
| - Code:
-
% Author: Claudia-Ann Gray 0702011 % Date: 9/21/2010
thief(tom). thief(arlene). underage(tom). underage(phil). underage(paul). underage(sara). overage(arlene). overage(mirelle). overage(caroline). overage(charles). helps(phil, mirelle). helps(paul, arlene). helps(paul, charles). helps(arlene, phil). helps(mirelle, sara). helps(charles, caroline). helps(caroline, tom).
criminal(A):-thief(A). criminal(F):-helps(F,A), criminal(A). adults(B):-overage(B). minors(C):-underage(C). prison(D):-criminal(D), adults(D). juvenile_centre(E):-criminal(E), minors(E).
| |
|