Created
February 15, 2015 00:55
-
-
Save JustinSDK/12ee1bcca7cd3ca5fc6a to your computer and use it in GitHub Desktop.
〈Haskell Tutorial(25)可映射盒中物行為的 Functor〉的解答
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
instance Functor (Either a) where | |
fmap f (Right x) = Right (f x) | |
fmap f (Left x) = Left x |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment