[Haskell-beginners] constant set

Ovidiu Deac ovidiudeac at gmail.com
Sat Mar 10 01:24:33 CET 2012


If I want to define a constant set in Python I would do this:
class Colors:
  red = 1
  blue=2
...

and then I use them like this: Colors.red, Colors.blue...

Can I do something similar in Haskell?
thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/beginners/attachments/20120310/fd268ea6/attachment.htm>


More information about the Beginners mailing list