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.
Nice solution! Is there a reason for the return before dirReduc(arr)? Just curious because I tried it without the return and it also worked.
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Could you explain the 60 % 60?
I am wondering if this could be just sorted.slice(-1) without the [0]?
This comment is hidden because it contains spoiler information about the solution
I think there is a typo, it should be: The round yellow light on top blinks to denote odd- (when lit) or even-numbered (when unlit) seconds (as written here: https://en.wikipedia.org/wiki/Mengenlehreuhr)
Please can you change it in the question?
Many thanks
Sorry, a bit confused, could someone explain how this code works - I don't understand how pop() works on an empty array? What exactly is being popped and pushed?
Nice solution, I find it very clear.
Can I ask why you multiply by 60000 to get the milliseconds? Why is milliseconds needed?
I'm having the exact same problem as Buddha_B
It works on chrome console but not here?
Basic tests
Test Passed: Value deep equals [3, 3, 3, 5, 5, 7, 7, 2, 9]
Expected: [1, 1, 1, 0, 0, 6, 6, 8, 8, 2, 3, 5, 9], instead got: [1, 1, 1, 0, 0, 6, 6, 8, 8, 9, 5, 2, 3]
Test Passed: Value deep equals [9, 9, 9, 9, 4, 4, 5, 5, 6, 6]
Test Passed: Value deep equals [1, 1, 2, 2, 3, 3, 4, 4, 5, 8]
Test Passed: Value deep equals [0, 0, 4, 4, 9, 9, 3, 5, 7, 8]
As you can see, in the tests that I pass, there is the same logic applied as the one that I do not pass. Not sure where I am going wrong?
Is the starting accumulator a 2 element array because the result needs to be a 2 element array? ie. does the format of the accumulator have the be the format of the final output?
Sorry if my question is basic but what is the line input = input.replace for?
Why does the input need to be replaced?