Re: Only the first answer

Wouter Beek <[email protected]>
Newsgroups gmane.comp.ai.prolog.swi
Message-ID <CAE1un7Nr0ucazrmbZ8qMphu9ukbFQQe73KgyHHEFZ2pZ9wfE+Q@mail.gmail.com>
Hi Diego,

Do you mean the cut <http://www.swi-prolog.org/pldoc/doc_for?object=!/0>?
It discards the choicepoints that occur before it. Also see
once/1<http://www.swi-prolog.org/pldoc/doc_for?object=once/1>
.

---
Cheers,
Wouter Beek.

E-mail: [email protected]
WWW: www.wouterbeek.com
Tel.: 0647674624


On Sun, Aug 25, 2013 at 4:15 AM, Diego Rafael Di Berardino <
[email protected]> wrote:

> Is there a way to make prolog stop to process when it finds the first
> answer to the goal, and not to lose time with other answers?
>
> Thanks.
> -------------- next part --------------
> HTML attachment scrubbed and removed
> _______________________________________________
> SWI-Prolog mailing list
> [email protected]
> https://lists.iai.uni-bonn.de/mailman/listinfo.cgi/swi-prolog
>
>
-------------- next part --------------
HTML attachment scrubbed and removed
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.