Created
July 29, 2014 08:18
-
-
Save nobsun/265e67f54ef562f32693 to your computer and use it in GitHub Desktop.
This file contains 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
ssum :: Num a => [a] -> [a] -> a | |
ssum = foldr f (const 0) | |
where | |
f x g [] = 0 | |
f x g (y:ys) = x * y + g ys |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment