Advertisement
Guest User

Colour

a guest
Mar 16th, 2015
294
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. -- | Practice with Data types
  2.  
  3. data Colour = Brown | Red | White | Black deriving (Enum)
  4.  
  5. instance Show Colour where
  6.     show Brown = "Brown"
  7.     show Red = "Red"
  8.     show White = "White"
  9.     show Black = "Black"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement