Answer by Mark Seemann for Haskell Evaluation
The problem seems to be that you want to use example to 'update'n. You can't directly do that, however, since example returns a G value, and n is an Int.It seems, then, that you need a function G ->...
View ArticleHaskell Evaluation
I have the following block of code:data G = F G G | H Int deriving (Show, Eq)example :: Int -> G -> Gexample 0 (H i) = (H i)example n (H i) = F (example (n-1) (H i)) (example (n-1) (H i))example...
View Article