diff options
Diffstat (limited to 'lec08/Party.hs')
| -rw-r--r-- | lec08/Party.hs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lec08/Party.hs b/lec08/Party.hs index 7163eaf..744d3e4 100644 --- a/lec08/Party.hs +++ b/lec08/Party.hs @@ -67,3 +67,8 @@ nextLevel boss outcomes = (bestWith, bestWithout) where bestWith = glCons boss $ mconcat $ map snd outcomes bestWithout = mconcat $ map (uncurry max) outcomes + +-- Exercise 4 + +maxFun :: Tree Employee -> GuestList +maxFun hierarchy = maximum $ treeFold nextLevel hierarchy |