projects
/
lambda.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bb4e439
)
whoops, tree_best_sofar (direct) had a bug
author
jim
<jim@web>
Tue, 24 Mar 2015 13:12:24 +0000
(09:12 -0400)
committer
Linux User
<ikiwiki@localhost.members.linode.com>
Tue, 24 Mar 2015 13:12:24 +0000
(09:12 -0400)
exercises/assignment5_answers.mdwn
patch
|
blob
|
history
diff --git
a/exercises/assignment5_answers.mdwn
b/exercises/assignment5_answers.mdwn
index
0cdfa61
..
1780b0a
100644
(file)
--- a/
exercises/assignment5_answers.mdwn
+++ b/
exercises/assignment5_answers.mdwn
@@
-263,7
+263,7
@@
Choose one of these languages and write the following functions.
let rec tree_best_sofar (t : 'a color_tree) (lead : maybe_leader) : maybe_leader * int =
match t with
- | Leaf a -> (
None
, a)
+ | Leaf a -> (
lead
, a)
| Branch(l, col, r) ->
let (lead',left_score) = tree_best_sofar l lead in
let (lead'',right_score) = tree_best_sofar r lead' in