S
S
Savva Corps2014-11-16 00:27:51
Prolog
Savva Corps, 2014-11-16 00:27:51

What known Prolog interpreter can decipher this code?

There is Prolog code for finding combinations in a given
comb(0,_,[]) list.
comb(N,[X|T],[X|Comb]):-N>0,N1 is N-1,comb(N1,T,Comb).
comb(N,[_|T],Comb):-N>0,comb(N,T,Comb).
But neither gnu nor swi can run it. One does not accept empty parentheses, the other thinks that the comb predicate has never been identified. Please help in identifying the language interpreter, and if possible with a translation to gnu.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Savva Korps, 2016-05-15
@SavvaZombie

Answer to myself after a year. swish.swi-prolog.org starts and runs great , in theory this is a truncated version of Swi, but oddly enough, unlike this, Swi works flawlessly

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question