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.
Okay sounds fair! :) Thanks.
@xDJxYummY Worked like a charm! Thank you for the help.
My code works for most of the test cases but for some (13) tests cases it fails. And for almost all of them it shows, expected 'Nothing' instead got (some array)
For start and limit [2177,4357] i get a pair [2295, 2024] as answer.
For start and limit [70755,82611] i get a pair [75495, 62744] as answer
For start and limit [543020,553517] i get a pair [544784, 526575] as answer
For start and limit [202903,212274] i get a pair [206504, 186615] as answer
and more...
Can someone help me? What am i doing wrong? Should i post my code?
Do people write this type of code in production level software? I mean, maybe its just me, but this type of code is difficult to understand for others (anybody who takes over the project from you, or some new junior). And one can maintain code better only if they understand it.
Just curios.
I understand it is a one-liner and it usses various es6 features but still wouldn't traditional for loop be better in this case? Is this sort of code giving better time or memory complexity that i can't understand or is it just the prefernce of the coder?
How the fuck do people even come up with such solutions?
I mean do people write such code in production level code as well?