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.
I would be impressed if you didnt use a script to generate that and wrote every piece like a true unga bunga code chad
I'm already timing out on the first couple of small random tests. Perhaps this kata should be tagged with "performance".
It's very good don't worry.
Thanks for your hard work; I hope you don't mind but I printed this out and put it on my wall, so I have a handy reference for whenever I need to know which century I am currently in (I'm a time traveller so I need to do this about 2-3 times per week).
By the way, since I'm a time traveller, I already know you're going to upvote my comment.
Yay! My third
1kyu
kata. :]Use a table instead of a code block? Markdown can do tables.
explanation is pretty clear
the tick and cross marks in the example aren't aligned with the actual values of the list, so that could be a bit better imo
The table headers are visible now
@akar-0 This is a regression from the recent dependency update. The kata is not changing the style.
I'll look into it, and fix it as soon as possible.
See: https://docs.codewars.com/authoring/guidelines/description
In dark mode the table headers are not clearly visible. Can you suggest a way to change color to avoid this problem?
Data.Foldable has a strict foldr, defined in terms of foldl, which is in turn defined in terms of foldr. So with the right ( wrong ) function and initial value, you can lose laziness.
I haven't constructed a counterexample, but I'd hazard a guess it can be done.
It would be much more complicated than the example solution of course, but you never know what people come up with.
If it's tested, it should probably be in the specs BTW. But we're still in Beta. :]
I also suggest testing for laziness with an approximation of infinite lists. See my fork.
Why not? With
QuickCheck
it's pretty much automatic.This comment is hidden because it contains spoiler information about the solution
Loading more items...