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.
'Much better, yep.
It invalidated my initial solutions.
About that, you should increase the number of random tests to 250, so that there is slight chance a case like this gets generated during the random tests.
The python test framework is described in the docs.
Cheers
Edit: when said "fixed tests first", this means the functions that are only related to random tests should be defined after the fixed tests.
Thank you for your feedback,
I have attempted to make the improvements mentioned and I hope they are suitable.
thank you for informing me about test.expect, I didn't know it existed.
I don't know why that fixed test was considered missing, but I will still include it.
Hi,
The tests need to be rewritten so that the code is maintainable
useok, the process is actually very weird. I'd suggest you returntest.expect(check, msg)
instead oftest.assert_equals
, here""
in case of success, so that you can dotest.expect(not outcome, outcome)
{"blue":16,"red":8,"black":2,"orange":2,"purple":2}
Cheers
thank you, I have edited my tests to use copies of the original dictionary instead of using the original dictionary, which should resolve my mistake
This comment is hidden because it contains spoiler information about the solution
I just noticed another mistake that was allowing return [] to cause tests to pass, this mistake has been corrected
I made a mistake when creating a test that lead to it always returning true, the test has been fixed, so the random tests should work now
Needs random tests.
this answer doesn't even work it just got lucky that on the attempt there were no instances of the variable having a coefficient of -1 with an even exponent. I fixed the problem in my second submission, just found it funny that this incorrect answer was accepted