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.
Hi, I've been trying to complete this kata, but I'm stuck. I think I have some issue with rounding maybe... because it looks like most of the tests are off just sometimes and by just a few hundredths
For example:
Unhandled rejection TestError: Random - Expected:
[['0.55', '2.14'], ['0.45', '1.61'], ['0.95', '4.73'], ['1.37', '4.15'], ['0.51', '4.22'], ['0.43', '5.35']], instead got:
[['0.54', '5.28'], ['0.44', '4.75'], ['0.93', '4.73'], ['1.35', '4.15'], ['0.49', '4.22'], ['0.41', '5.35']]
o_O
Damn yeah. I shortened it to to isolate the problem + to see if it'd resolve other issues. Thanks again for help
Nice.
But most of random cases expect only 1-length-array.
You better fill it with more data to actually test if
The rifle will shoot closer enemies first.
is correctly implemented.Cheers!!
FIXED IT!!!! BOOOOM!
Maybe there are some edge cases which cause your solution a infinite loop.
You can log random data to see what happended.
Actually it's for both validate and publish. I think it's taking too long to process so it's timing me out. Kind of weird seeing as it does the basic tests in a fraction of a second. Surely it should only take double the time for random tests?
Ahh phew! Yeah it's the former but it only happens when I try to do more than 3 random tests. I'll keep trying!
You mean you get timeout whenever you
PUBLISH
orVALIDATE SOLUTION
?The former one is usual in CW, you just need to try again and again (sometimes even if you got a timeout feedback, the code is actually updated).
The later one means there are problem with your solution.
Hi,
Thanks for your help. I do have a problem with adding additional iterations on the random tests. It seems to cause a network error? Does this mean I should try and simplify my code? I've made the other amendments.
Test.assertDeepEquals
instead ofTest.assertSimilar
Sample tests and description expect wrong result
Hahah yep, silly mistake. Cheers for the pointer
No, the tests are fine, it seems you're the one that's mutating the input, check the note.
Loading more items...