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

name = 'sum/2'
slug = 'find the sum of all elements in list'

description = '''\
<p><code>sum(L, Sum)</code>: <code>Sum</code> is the sum of all elements in the list <code>L</code>.</p>
<pre>
?- sum([1,2,3], Sum).
  Sum = 6.
</pre>'''

hint = {}