Re: Can I do something like this

[email protected]
Newsgroups gmane.comp.ai.prolog.swi
Message-ID <[email protected]>
>> On 24/03/2014, at 9:05 AM, Roelof Wobben wrote:
>>
>> > I have a predicate which has 2 possibilities.
>> >
>> > the parameter is substained or not.
>>
>> What the dickens does "sustained" mean?

[Still no answer to that.]

> At this moment I m following the adventure in Prolog tutorial of Amzi.

I haven't seen that before.
Did you read
http://www.amzi.com/AdventureInProlog/a10unif.php
because that tells you precisely what you got wrong here.

> What I try to make work is to make a difference between my_predicate(x)
> and my_predicate(item).

Let me give you a clue.
These are variables: X Y Z Item Green_Eggs_And_Ham Molière Ot&#257;go.
These are constants: x y z item green_Eggs_And_Ham molière ot&#257;go.
x and item are different constants, but both of them are constants.

> I m aware that I drifting away from that tutorial
> and mainly that is because Im experimenting with some ideas.

That is good.  But before you experiment with some ideas,
make sure you have learned the ideas the tutorial is trying
to teach you.

It must be said that the technical language Amzi use is
peculiar:  they call 'primitives' what other people call
'atomic terms' or 'constants', and they call 'structures'
what other people call 'compound terms' and they get
'functor' thumpingly wrong.  They talk about variables
being unified 'to' each other instead of 'with' each
other, which isn't just peculiar Prolog, it's peculiar
English.  And yet, and yet, the basic material is _there_.

You know,
http://www.amazon.com/The-Art-Prolog-Second-Edition/dp/0262691639/ref=sr_1_1?ie=UTF8&qid=1395648154&sr=8-1&keywords=Sterling+and+Shapiro+the+Art+of+Prolog
says you can get a used copy of Sterling & Shapiro for USD 3.27
+ postage -- click on the link and there are quite a few copies
at that price.  So far, you've used -- at typical consulting
rates -- about a hundred times as much worth of other people's
time.

Oh, wow!  There's an ISO edition of Clocksin & Mellish,
which came out late last year.  And it's cheap!
http://www.amazon.com/Programming-Prolog-Using-ISO-Standard/dp/3540006788/ref=pd_sim_sbs_b_1?ie=UTF8&refRID=10BNGFN093BMX28SDMPS
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.