Re: How to return clause in findall/3

From: Pere Montolio (tmp123_at_menta.net)
Date: 08/13/04


Date: 13 Aug 2004 01:18:55 -0700


"rhapsody" <blurrynight@yahoo.com> wrote in message news:<f58aded771bea22dbd46076ee25f9533@localhost.talkaboutprogramming.com>...
> Is it because I am using Visual Prolog? It gives error says 'variable
> expected' at the [A,B,C]
>
> findall([A,B,C],sc(A,B,C),List), write(List), nl.

It seems there are a difference between SWI and Visual. In Visual, try:
findall(A,sc(_,_,A),List).