Subject: [SWIPL] another question

From: Partsakoulakis Ioannis <[email-masked]>
Date: Thu, 31 May 2001 20:27:46 +0300

I want to ask how can I define a predicate
a(+Term,+ListOfTerms,-ListOfInstances) such that if term Term is unifiable
with a term in ListOfTemrs then ListOfInstances will contain the
correspinding instance of Term. For example if ask

?- a( p(1,X), [p(Y,2),p(2,1),p(1,3)], L ).

I want to take

L = [p(1,2),p(1,3)].

Can somebody help me?

Thanks,

Yannis.