[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: small files in GProlog

From: Nicolas Pelletier
Subject: Re: small files in GProlog
Date: Tue, 26 May 2009 14:32:07 +0900


On Mon, May 25, 2009 at 5:07 PM, Robert SETIF <address@hidden> wrote:
> I am a new user of GProlog and I cannot write a correct file myself in spite
> of the  Help (accompanying the Software ), Help  that I find very abstract,
> more convenient for developpers than for beginner users.

This is a very general statement that is not going to help improving
what you see as a flaw. Try to point specifically to what needs to be
improved, and say how you would like it improved, for example by
submitting your explanation or a pattern for it. Keep in mind, though,
that the manual documents the GNU Prolog compiler, not the language
Prolog itself.

> That is why I need very small programs which  allow me to experiment them,
> and so to try modifying them for seing the results.
> Where finding such files?

Did you google ? Anyway, here is a very simple example to help you get started:

address@hidden:~/dev/prolog$ cat > <<EOF
> :- initialization( go ).
> go :-
>     write( 'Hello, world !' ),
>     nl,
>     halt.
address@hidden:~/dev/prolog$ gplc --no-top-level --min-size --output
address@hidden:~/dev/prolog$ ./example
Hello, world !
address@hidden:~/dev/prolog$ ls -l example*
-rwxr-xr-x 1 nicolas nicolas 182576 2009-05-26 14:08 example
-rw-r--r-- 1 nicolas nicolas     81 2009-05-26 14:08

Hope this helps,


reply via email to

[Prev in Thread] Current Thread [Next in Thread]