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.
devils in the detail with this one
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 is perhaps the first such integer: 1125899940397056. For this input, the answer should be 1125899906842624, but it gives 1125899973951489.
And the total number of such safe integers is tens of millions.
Please, dude, stop using CHATGPT, what Yuri said.
Cleanest solution so far
I think a best practice is to always use a Named function instead of an Arrow function for easy error location and handling.
do you still the parameter if you dont need to use when using a arrow function ?
oh, ok. thanks for answering
For fun.
why replace function with a constant?
nic solution
OMG
This is a good solution, I love it.
I didn't know the method every
the way you used the rest operator
it is much more elegant and solves the problem for many divisors
Same with me, gave the try reading https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/Arrow_functions , but still can't nail it hehe 🤣.
Next time will be!
Loading more items...