Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
The haskell tests are totally broken; there are several solutions that just return a static string that succeed. Please fix!
Honestly pretty disappointed that the tests only accept a certian tree for
pass1
. I really like the way I implemented it with the tree going the other way but now I have to refactor everything to get it going the other way and I'm having a really tough time of it.for example
1+2+3+4
right:
Add (Add (Add (Imm 1) (Imm 2)) (Imm 3)) (Imm 4)
wrong:
Add (Imm 1) (Add (Imm 2) (Add (Imm 3) (Imm 4)))
Old version
I just finished my solution and I have a habit of working on these without even looking at the function definition. I was surprised when I saw it using
Text
instead ofString
but ultimately it was very easy to adapt my solution to useText
instead.Text
also has a few more useful functions thanString
, but I had to install the package to work with it on my machine. For what it's worth, I thinkText
is fine.That's a bit rude, but not really. I'm a beginner to haskell and this is the solution that made sense to me. It just means I have more to learn :)