We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7a73b6b commit 04e1e91Copy full SHA for 04e1e91
L05_files/tree.png
7.29 KB
lec05.html
@@ -600,10 +600,12 @@ <h1>Homework</h1>
600
<h2>Trees in Haskell</h2>
601
<ol>
602
<li>Fill out <a target="_blank" href="https://docs.google.com/forms/d/1Jc0H2JCWLuVFN97iLXqqZHTFpznOKv8_C7WDm6FnzYg/viewform">this week's form!</a></li>
603
+
604
<li>Create a binary tree data type of Int nodes</li>
605
<pre><code class="haskell">data Tree = ... </code></pre>
606
<li>Write a function to sum all nodes in the tree</li>
607
<pre><code class="haskell">add :: Tree -> Int</code></pre>
608
+ <center><a target="_blank" href="http://en.wikipedia.org/wiki/Binary_tree"><img src="L05_files/tree.png"></img></a></center>
609
</ol>
610
</section>
611
0 commit comments