Ad
  • Default User Avatar

    From the description: "This means that being r = result, r^n = x;"

    is not really clear. Waybe reword to (root x n)^n = x?

  • Default User Avatar

    The description of the kata is all messed up.

  • Default User Avatar

    Isn't there are some issues with writing an instance of Ord like this? Some hands will be tied according to Poker rules, and I guess EQ will be returned in those cases. However, this means that the Ord instance will not be a total order (indeed, not even a partial order). This means that you can't store hands realiably in a container relying on Ord, e.g. Data.Map or Data.Set.

  • Default User Avatar

    It feels a bit clunky to have a fold function that takes seven functions. But you are of course correct.

  • Default User Avatar

    The function called "i" in the text and code should be named "l", since this is what the test expects.

  • Default User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Default User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Default User Avatar

    Sounds like a great idea!

  • Default User Avatar

    Maybe. On the other hand, it is meant to be easy.

  • Default User Avatar
  • Default User Avatar

    Thank you for your feedback ajnsit. I have added a link to HaskellWiki about newtype. However, I do not see the point of the hiding the declaration; you would never have that situation when actually programming.

  • Default User Avatar

    This seems really interesting to me, but I am not sure I grasp all the language features used here.
    I think one of the major stumbling blocks for me is the line:
    type Term a = forall r h . Language r => r h a

    What does this mean? Is there maybe a Haskell wiki page that can be linked to explain this?
    Maybe the author wants the user to find this by him- or herself, in which case it is of course fine, but I think that if you want people to learn from this, some basic links could wouldn't hurt.

  • Default User Avatar

    What should happen with a singleton list?