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.
You need to search in the given number for the smallest digit, in "261235" it is 1 which is in position 2 or in index 2. to make "261235" smaller I take 1 and move it to the beginning to position 0 obtaining 126235. then my answer is [my smallest number, the index from where I got 1, the position where I put it in this case 0] = [126235, 2, 0]
1.) Is the priorty this : first = smallest number, second = smallest I index, third = smallest J index ?
If that is true I have a test response of :
expected [ 261235, 2, 2 ] to deeply equal [ 126235, 2, 0 ].
Thanks for the help with this head scratcher.
hehehee same.
and thinking while I was implementing my huge repetitive code with uninon
"there's no way there isn't a better way to solve this"
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
what was an error in your code?
So I was wondering how the expected does the calculation for median.
Since my solution for median is correct but the expected was giving
values like 55.5 and 64.5 when these values didn't exist in the list of scores
and median is get the middle value.
Example :
1,3,5,7,9 = 5
1,22,33,34,35 = 33
The value most be the middle number in the list.
Could you give me a hint to what the problem in my code is ?
As far as I can see the actual matches the expected.
So why should it not be seen as a valid solution.
The tests work okay, and the problem comes from your code. The error messages are not clear indeed, but that's the problem with the runner, and not with the kata.
This comment is hidden because it contains spoiler information about the solution