Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
folder
folder :: (a->b->b) -> b -> [a]-> b folder (#) e [] = e folder (#) e (x:xs) = x # folder (#) e xs --product = folder (*) 1 --and = folder (&&) True --sum = folder (+) 0 --or = folder (||) False main = print $ folder (+) 1 [1,4,7,3,67]
run
|
edit
|
history
|
help
0
tried some polynoms 2: now with some `*` and foldr(-p)
haskell
project euler 3, haskell
haskell_exam
Modeling algebraic understanding with Haskell in KS1
pascal triangle
boolean functions of zero arguments in haskell
haskell fibonacci
ReadablePractice
project euler 2, haskell