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 real mvp here, good call that it's bitwise via &
I see. Thank you.
Sergio, this returns true when divisors x and y leave the same remainder, right?
e.g. (11 % 2) == (11 % 5) // (1 == 1) true
but 11 is divisible by neither 2 nor 5, and should return false.
Oh thanks i didn't even think about it as unsafe. Just learned it from 'reverse string challenge' with limited characters. And this kumite is honestly, but a test. Was wondering what is this, found out after submitting. I'll find a way to delete it, i guess.
You basically defined a function without any declaration. I feel like you should know the many dangers involved with that practice. Check out this link for more information.
https://www.sololearn.com/Discuss/2191625/javascript-arrow-functions-with-and-without-const
Wanted to extend the idea of using default parameters. I wish I could keep the spread operator, but it must be the last, and default params are set left to right.
In case anybody misread like I did:
"sum of the integers to the left of N is equal to the sum of the integers to the right of N"
I interpreted this as sum of N from the left == sum of N from the right, and I couldn't understand why the first test failed on [1,...,1] which returns 0 (in my incorrect code).
Read carefully!
Thanks for the kata.
This comment is hidden because it contains spoiler information about the solution
Why not just return everything on the right side of the || operator? I don't understand what the comparison to !str gets you. Halp please.