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.
now also on dart
Translation Dart
I guess you also made those changes in the note app then.
I've just erase the "instead" on my note app ^^
@Chrono, it works thank you :)
I don't see how you could possibly obtain this error message
that is not at all what the error messages look like when I run it, for example, you've written
"Got :"
with two line terminators before it, while the actual output is ", instead got:" with no line terminator, and the expected one is 5 while got is -40, a closing double is missing, spaces appearing out of nowhere ..this is what they do look like:
I copied and pasted your code, removed the space at the end, and passed both sample and attemp tests.
Thank you Chrono, but i've already this option (has many others) and it doesnt work.
Remove that space you've added at the end, and your code will pass.
seems to be impossible to resolve with ruby :/
I've test every possible options...
But on every i'm turning between those results :
Expected : "1 * 5 = 5\n 2 * 5 = 10\n 3 * 5 = 15\n 4 * 5 = 20\n 5 * 5 = 25\n 6 * 5 = 30\n 7 * 5 = 35\n 8 * 5 = 40\n 9 * 5 = 45\n 10 * 5 = 50
Got : "1 * -40 = -40\n 2 * -40 = -80\n 3 * -40 = -120\n 4 * -40 = -160\n 5 * -40 = -200\n 6 * -40 = -240\n 7 * -40 = -280\n 8 * -40 = -320\n 9 * -40 = -360\n 10 * -40 = -400"
or
Expected : "1 * 38 = 38\n2 * 38 = 76\n3 * 38 = 114\n4 * 38 = 152\n5 * 38 = 190\n6 * 38 = 228\n7 * 38 = 266\n8 * 38 = 304\n9 * 38 = 342\n10 * 38 = 380"
Got : "1 * 38 = 38\n 2 * 38 = 76\n 3 * 38 = 114\n 4 * 38 = 152\n 5 * 38 = 190\n 6 * 38 = 228\n 7 * 38 = 266\n 8 * 38 = 304\n 9 * 38 = 342\n 10 * 38 = 380"
Once it doesnt wants the space after the results, and the next time it wants it.
It looks like you might be overwriting the expected result in memory, there is no issue with the tests.
Isn't the following expectated result wrong?
random_tests
for matrix:
{
{-48, 34, -42, 20, 40, -77, -53, 32, 57, 38},
{-34, -80, -3, -7, -12, 37, 83, -92, 3, -44},
{47, 44, -8, -14, -86, -95, -48, -44, 71, 29},
{-54, -77, -38, 5, 43, -98, 28, 91, 34, -15},
{29, -100, 5, -74, -7, 94, 63, -24, -99, -34},
}
expected:
38,5,43,-98,28,91,34,-15
29,-100,5,-74,-7,94,63,-24,-99,-34
Enabled in this fork
Updated to Node 18
Fixed (remember that you need to RESET the trainer to get the fixed code).
JavaScript sample tests do not import chai.
No, your code is just keeping track of which
indices
are even, not their respective actual array values.Loading more items...