I am trying to compile csp.pl from "Computational Intelligence book" which solves the constraint satisfaction problem. I want to use this as a base to solve crossword puzzle generator.
But when I try to run the code it gives
Existence error in user:remove/3
! procedure user:remove/3 does not exist
! goal: user:remove([1,2,3,4],3,_127)
| ?- :-
I think remove is not a built-in predicate
% select(E,L,L1) selects the first element of
% L that matches E, with L1 being the remaining
% elements.
select(D,Doms,ODoms) :-
remove(D,Doms,ODoms), !.
% choose(E,L,L1) chooses an element of
% L that matches E, with L1 being the remaining
% elements.
choose(D,Doms,ODoms) :-
remove(D,Doms,ODoms).
This is the part of the code... Can anyone please help me fix this issue... Code should execute since in the textbook its claimed to hv run on some programs..
Please help