Related questions
'if' in prolog?
Is there a way to do an if in prolog, e.g. if a variable is 0, then to do some actions (write text to the terminal). An else isn't even needed, but I can't find any documentation of if.
Prolog "or" operator, query
I'm working on some prolog that I'm new to.
I'm looking for an "or" operator
registered(X, Y), Y=ct101, Y=ct102, Y=ct103.
Here's my query. What I want to write is code that will:
"return X, given that …
"Not equal" sign in Visual Prolog?
I can't find any documentation on "not equal" sign in Visual Prolog. Please provide the right solution of this problem:
class predicates
sister : (string Person, string Sister) nondeterm(o,o).
clauses
sister(Person, Sister) :-
Person [not-equal-sign] Sister,
parent(Person, …