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.
What happens if you drop the stack from your solution? Does it work the same without it?
Looking at your code, I'd say ")(" is probably the simplest case that will make it fail.
Print out important variables to see what your code does.
You got this part wrong. Sample tests are OK, and your solution has an error and returns wrong results.
Run your solution locally, in your IDE, for example with parameter
""
(i.e. empty string). Sample tests expect it to returnTrue
. Check locally what it returns. It will probably make easier for you to find your mistake.But that's what I am saying. Please check the sample tests. Whatever the two tests (failing) are expecting is what my code is giving as outputs. The error thrown says the opposite.
Not an issue. Your solution doesn't even pass the
""
sample test. And use spoiler tags.This comment is hidden because it contains spoiler information about the solution
Mutating the input is changing the parameter in a function. For instance:
Thanks for that.
A quick one before you go. I am still getting my hands dirty with all this. Could you send a resource on this input mutation. I am not sure I understand what is meant and could not find any resource that quite explained it well. I came across it in another kata I was doing and didn't finish it as it was the only test failing.
Thanks.
Don't mutate the inputs. Never. Unless you're told you can explicitely.
But so, it was an issue.
edit: corrected
This comment is hidden because it contains spoiler information about the solution
Not an issue. Print the inputs.
My implementation in Python fails one of the basic tests yet outputs exactly what is expected from the failing test. Any assistance?