summaryrefslogtreecommitdiff
path: root/prolog/problems/sets/intersect_3/en.py
blob: fefc50a8bb1a76ed71432e824302b0456bd65648 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
# coding=utf-8

name = 'intersect/3'
slug = 'find the intersection of two sets'

description = '''\
<p><code>intersect(S1, S2, I)</code>: the list <code>I</code> contains every element that appears in both <code>S1</code> and <code>S2</code>, with no duplicates.</p>
<pre>
?- intersect([1,5,6,3,4,2], [8,1,5,9,4,3], I).
  I = [1,5,3,4].
</pre>'''

hint = {}