Welcome! Log In Create A New Profile

Advanced

Ok, I'm stuck

Posted by Kilhra 
Announcements Last Post
Announcement SoC Curricula 09/30/2017 01:08PM
Announcement Demarcation or scoping of examinations and assessment 02/13/2017 07:59AM
Announcement School of Computing Short Learning Programmes 11/24/2014 08:37AM
Announcement Unisa contact information 07/28/2011 01:28PM
Ok, I'm stuck
April 23, 2010 07:20PM
I've just started with chapter 3 and for the life of me I can not get the membership relation to work.

M code looks as follows:

member(X,[X|Tail]).
member(X,[Head|Tail]) :-
	member(X,Tail).


if I input something like

?- member(b,[a,b,c]).

i get 'no' in return


What am I doing wrong?
i ooked for examples on the net, even copied and pasted some example code for this, but it will not work.
Re: Ok, I'm stuck
April 23, 2010 07:46PM
*sigh*

i was using the listener the wrong way.

Have to start it and say consult.
Though I can't remember doing it previously (it has been a couple of weeks though)
Sorry, only registered users may post in this forum.

Click here to login