summaryrefslogtreecommitdiff
path: root/prolog/problems/trees/tolistbt_2/sl.py
diff options
context:
space:
mode:
authorTimotej Lazar <timotej.lazar@fri.uni-lj.si>2016-04-11 00:10:57 +0200
committerTimotej Lazar <timotej.lazar@fri.uni-lj.si>2016-04-11 00:10:57 +0200
commitacce0e01cdb2a57cda35e040035dbf1da6b96031 (patch)
treee5a08e4a45893463e7bacfd82454a1a07fecba69 /prolog/problems/trees/tolistbt_2/sl.py
parent169c995732f3840aae6750479b49a4d0bcd4b198 (diff)
Prolog: add test cases for the trees group
Diffstat (limited to 'prolog/problems/trees/tolistbt_2/sl.py')
-rw-r--r--prolog/problems/trees/tolistbt_2/sl.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/prolog/problems/trees/tolistbt_2/sl.py b/prolog/problems/trees/tolistbt_2/sl.py
new file mode 100644
index 0000000..5545c51
--- /dev/null
+++ b/prolog/problems/trees/tolistbt_2/sl.py
@@ -0,0 +1,11 @@
+name = 'tolistBT/2'
+slug = 'vrni seznam elementov binarnega drevesa'
+
+description = '''\
+<p><code>tolistBT(T, L)</code>: seznam <code>L</code> vsebuje vse elemente binarnega drevesa <code>T</code> v infiksnem vrstnem redu.</p>
+<pre>
+?- tolistBT(b(b(nil,2,nil),1,b(nil,3,nil)), L).
+ L = [2,1,3].
+</pre>'''
+
+hint = {}