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 link posted by 10XL is not relevant for JS so i wouldn't waste my time there.
unmarked it as spoiler
I think that comment is blocked from me. Sorry I am still getting familiar with how this site works.
benjaminadk, the link I posted in my comment above is also relevant for JS and Ruby.
I am also having this problem with javascript. I put an empty object at the
leaderboard#position[0]
position and I pass every test except the 500 length. Mine is 501. I am going to try to remove a random user and hope to cheat by the tests. However, I am wondering if there is something I am missing or not aware of that will allow me to conform to the desired results. Other than that, cool kata - I had no clue that libraries likecheerio
could be brought in.JS: I have the same problem using an array, either have 501 length or fail the 500 user name. Any pointers?
Good kata, really enjoyed it
Yeah, I'm stuck now here, too. I didn't think it was going to be a problem beause simplying
shift
ing the first scraped element worked for the sample tests... but it doesn't work for the main tests. I'm passing all but the one test, which is the 500th user's name. it is in there, but it's not at the 500th index for reasons apostonaut metnioned...in python2.7 (int / int is int) if you want a float try (float(int) / int)
in python3 (int / int is float)
hope this can help you
This is only true for lists/arrays. Here's a map of python data structures.
How can I handle the 1-based indexing? The second element of the position list has to be the first on the leaderboard, and the 500th element must be the 501st on the list but there can only be 500 in the list? I don't see any way around this
General advice:
The test cases definitely have a bug. I run the same code on my IDE and get a different answer. My code gives a page count of 3 for the basic test case, but this kata returns 2.0. Not sure how this is happening, but there's definitely a bug in the test code