Created
December 17, 2016 15:44
-
-
Save deque-blog/891bbb44c787b0cc06f3a166f0c63dc9 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bstCount :: (Int -> Integer) -> Int -> Integer | |
bstCount rec n | |
| n <= 1 = 1 | |
| otherwise = sum [rec i * rec (n-1-i) | i <- [0..n-1]] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment