• ###### stabnitecommented on "Grasshopper - Summation" elm solution

This is actually best practice rather than clever (ok maybe clever) cuz it's O(1).

• ###### MobulaKuhliicommented on "One Line Task: Fix" kata

You should lookup what infix operators other than composition are provided in prelude.

• ###### Opabiniacommented on "One Line Task: Fix" kata

Well, I just can't manage it!

Are you supposed to make this pointfree or not, I wonder... I'm a character off, and nothing I try does it.

• ###### JohanWiltinkcreated an issue for "Folding trees" kata

Could really do with more rigorous testing.

• ###### DunetsNMcreated a suggestion for "One Line Task: Fix" kata

I'd allow one extra character for at least some variability in possible solutions, and they would still require firm grasp of the concept

• ###### haspiencecreated an issue for "Car Door Roulette - Easy Version" kata

Seems like a necroposting but it still does not account for edge cases.
https://www.codewars.com/kata/reviews/5de92cff10dfae00012aa8ff/groups/5e083ebf8c89df0001c5b680

• ###### haspienceresolved a question on "Folding trees" kata

They do not conflict, the second function is simply more general then the first one. Try to squeeze in one more type variable into your definition.

• ###### oshmkufacreated a question for "Folding trees" kata

What's the type of `foldRoseTree`? According to the simple test cases I implemented the `foldRoseTree` with type `(a -> [b] -> b) -> (b -> [b] -> [b]) -> [b] -> RoseTree a -> b`, but there is a function `roseDepth = foldRoseTree (const (+ 1)) max 0` in truly test cases, which is conflict with simple test cases.

• ###### haspienceresolved an issue on "Equational reasoning with scanl" kata

I guess for now.

• ###### haspiencecommented on "Equational reasoning with scanl" kata

I can constraint type signature of `scanl` and check inside what exactly is passed to it, the only thing is it will break almost all solutions, is it fine?

• ###### Voilecommented on "Folding trees" kata

Oh yeah, `foldr` also assumes the fold is associative.

Speaking of that, you should add some random tests and more complicated fixed tests. You can use `QuickCheck` to help you with the random tests ;-)

• ###### haspiencecommented on "Folding trees" kata
``````ghci> leafTree
LeafNode
(LeafNode
(LeafNode
(LeafLeaf 1)
(LeafLeaf 2))
(LeafLeaf 3))
(LeafLeaf 4)

ghci> appEndo (foldMap (Endo . LeafNode) (fmap LeafLeaf leafTree)) (LeafLeaf 10) -- some random base case
LeafNode
(LeafLeaf 1)
(LeafNode
(LeafLeaf 2)
(LeafNode
(LeafLeaf 3)
(LeafNode
(LeafLeaf 4)
(LeafLeaf 10))))
``````
• ###### haspienceresolved an issue on "Folding trees" kata

Oh, nice, thank you! Your solution only passed because of my poorly written tests (which I hope I fixed by now). The thing is you get a bunch of `Endo . LeafNode` combined one after another (as if we had a list), instead of our previous proper structure.

Here what `base` says about it:

For a general Foldable structure this should be semantically identical to,
`foldr f z = foldr f z . toList`

Updated.

• ###### Voilecreated a suggestion for "Folding trees" kata

Also, the 3 functions to be completed should be in reversed order, since ideally the difficulty should be paced from easier to harder ones, which currently seems to be in the opposite order instead. You might need to change the order of the tests too.