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.
Did you read this in the description:
(most tags are actually automatic, hence most aren't appropriate: the heuristic used is rather poor)
I suggest reading this
https://docs.python.org/3/reference/datamodel.html#special-method-names
And implement a linked list class, supporting iteration, indexing (get and set, possibly slicing), string conversion, concatenation,
==
,<
>
I imagine kata's using the class tag all sprinkled on some oop dust without it being very meaningful.
Ah. Right. Actually I could not see it. Hadn't solved it. Have now.
Your test code:
will crash for a correct solution, because a correct solution will raise an exception and it isn't caught.
note that you're calling your solution before calling
test.expect_error
, any exception will already have happened beforetest.expect_error
gets to runit's equivalent to this:
What you need to do is ..
yes, because of the spoiler flag and the fact that you didn't solve the kata yet. But we can see it.
What I don't understand is why you expect this to fail, for one, and for two, that's not th syntax to use withtest.expect_error
, iircactually, I don't get what the problem is. What is, according to your point of view, the problem in the full test suite? Can you provide a precise example? (input/actual output/expected output)
What exact code did you add to your sample cases?
You're probably adding something different from what's in the test cases.
I just checkd and everything is working correctly in python... => ?
What did you try to prove/do exactly, with this? I cannot follow what you say, sorry.
Thanks for feedback. The Kata description is updated to clarify that...
Should be fixed now.
Agreed, there might be some math involved.
Can be optimized to handle an upper bound of 1,000,000 once you found out what is the most time-consuming part.