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.
The return value is correct, as you need to not only make it up to the ghost, but you need to pass the ghost.
But indeed, the random tests should have a special test suite to prevent this, otherwise it's easy to hardcode.
.
I did make a few minor changes to the add_a_randomly and then increased the size of the pile in make_deck => (12,24)
Thanks, don't know how I missed that, it is fixed now.
Typo in description -
""GB"
->'GB'
Haskell translation, same as python. If something changes about the python one, lmk so I can update. I did crank up test count to 200. Don't tell anyone. Shh.
I think since you mention only "GB" is garbage, this solution should pass after all.
Couldn't this be done with ints instead? Count milliseconds or microseconds or something if you don't like a large unit like seconds.
In practice, choosing random floats isn't likely to pick ambiguous cases. But that's not necessarily a good thing, as those should be handled correctly. As @rdtheriault points out, those only get tested once in fixed tests.
Random tests could also be written such that they intentionally check before/at/after edge cases.
I see what you mean. Given the rules of garbage only being GB, Na, and then fake cards with an "a" added at the end, it is going look for cards that can't exist. Is there something you want me to change? It does follow the rules abliet with looking for cards that don't exist. Thank you for the input.
It has some invalid suits E R T and ranks A B C, I don't see how you could test that in a meaningful way though. Sure, could include garbage with those possible values, but, you can always pick some other invalid ranks/suits
I'm not sure if this is a testing issue (I'll explain in a bit) or an issue but I passed all the random test but one of the example tests failed and I used.
Was that test an edge case, if so, their needs to be more in the random test (testing issue).
Doesn't seem like it should be an issue with the system if others did not have the same issue, but might be something to look into.
This comment is hidden because it contains spoiler information about the solution
I don't think this solution should pass: https://www.codewars.com/kata/reviews/65cbc64fbc97274bd7d585de/groups/65ce8cd3e70dec00013cbfc0
Ok, I added "from solution import pick_em_up". I did not realize that is how it worked. Yes, I didn't like the nested if either. I did know the percents were not perfect and thought about doing the math for it but as you said, they are rather arbitrary and I needed some random statements that worked.
Thanks again for all your help.
Loading more items...