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.
Hey there, sorry it took so long to get back to you. Your issue is that you are editing the variable n. The random tests are then taking your solution's n and running it back through the algorithm. Instead of doing this, try duplicating n to some other variable and your solution should work fine. You will have issues with many other solutions if you continue editing the variable passed to you, so I would recommend never doing it.
This comment is hidden because it contains spoiler information about the solution
If you wouldn't mind, could you post your solution here with spoiler tags? I would like to see what you are seeing with the random tests.
Slightly modified, thanks!
The Submit tests for Ruby require different instructions than the test cases. The test cases correctly use the last digit as the first digit in the final result, but in the submit tests, the first digit is retained.
For example:
Even when I pass the manual tests, in the final test, what should be correct is marked wrong.
reverse_fun("3yrpm2qgku8fmcr7zadt7qwku4qecs")
Expected: "3sycrepqm42uqkgwkqu78tfdmaczr7", instead got: "s3cyerqp4mu2kqwgqk7ut8dfamzc7r"
In the second example in the instructions, I believe 0 and 25 need to be included. This can be confusing.
Hi. Can you explain to me what this does?
Try to avoid sorting.
I have a working solution, but it takes too long on the final submit. Any tips to point me in the right direction? Not sure how much more I can elaborate because I don't want to spoil.