Prolog n00b question: Doing whatever

Posted by dmindreader on Stack Overflow See other posts from Stack Overflow or by dmindreader
Published on 2010-03-31T20:29:44Z Indexed on 2010/03/31 20:33 UTC
Read the original article Hit count: 383

Filed under:

I want to load this simple something into my Editor:

Write:-repeat,write("hi"),nl,fail.

So that it prints "hi".

What should I do?

I'm currently trying to do File->New

and Saving a file named Write into E:\Program Files\pl\xpce\prolog\lib

When doing the query:

?-Write.

It's printing:

1 ?- Write.
% ... 1,000,000 ............ 10,000,000 years later
% 
%       >> 42 << (last release gives the question)

Why?

© Stack Overflow or respective owner

Related posts about swi-prolog