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.
Hey @hobovsky 👋
Just wanted to check in and ask how long the "Awaiting approval" phase usually takes/lasts?
This comment is hidden because it contains spoiler information about the solution
Why are we returning only the first gear rather than a full solution, does that make the problem easier in some way?
There is only a single real edge case in the hidden tests, and it's quite literally an edge case:
The highest possible input as per constraints: [1, 10000]
Hidden or not, this test should always pass if all the other cases work as well, without special attention to this specific case (unless the general implementation is wrong, in which case other tests from the random suite will fail too)
I'll add that to the description
Oh boy, why hide edge cases in "hidden" tests ..
Done!
Done!
Tests should most probably set
chai.config.truncateThreshold = 0
to avoid truncation of arrays in assertion messages.Random tests report inputs of failed cases, but fixed tests do not.
Done, cool.
My hardcoded solution does not pass anymore, so this issue is apparently fixed.
should be resolved now
Ill try to fix those asap. Thanks for the feedback. Writing tests was never my strong suite 😅
https://www.codewars.com/kata/reviews/682f3c9a92139607f178ed2f/groups/682f4354e2c92089fbc673e8
Chai
assertions instead of compat module for the obsolete, homegrown assertions library.undefined
causes tests to crash.pegs
, the modified array is presented as input in failure messages. Tests should ensure that the input array is not modified by user solution.