Created
April 24, 2017 11:10
-
-
Save mykhas/9f2de57651d45f50355436aa3a9b8dfe 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
sum' :: Num a => [a] -> a | |
sum' xs = case xs of | |
[] -> 0 | |
(x:xs) -> x + sum' xs | |
initials :: String -> String -> String -- чому не працює String a => a -> a -> a | |
initials fn ln = [f] ++ " " ++ [l] | |
where (f:_) = fn | |
(l:_) = ln |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment