Newbie question...simple rule question...
- From: "mans" <mshapshak@xxxxxxxxx>
- Date: 11 Aug 2005 05:14:45 -0700
Dear All,
I am trying to understand the best way to write a rule which checks on
all the elements.
-------------
people(a).
people(c).
ok(b).
ok(a).
everybodyok_works :- findall(X,ok(X),List),maplist(people,List).
everybodyok_bad :- people(X),ok(X).
-------------
What am I missing? Is there a better way to write rule which says:
"Everybody is ok if for all people we know has said they are OK." ?
Thanks in Advance,
Mans
.
- Follow-Ups:
- Re: Newbie question...simple rule question...
- From: Mauro Di Nuzzo
- Re: Newbie question...simple rule question...
- From: Jan Wielemaker
- Re: Newbie question...simple rule question...
- Prev by Date: Re: RPLACA, anyone?
- Next by Date: Re: Newbie question...simple rule question...
- Previous by thread: limited number of iterations
- Next by thread: Re: Newbie question...simple rule question...
- Index(es):