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.
Thank you... i wasnt asking for "xor" actualy... i didnt know the operator "^" :D
This comment is hidden because it contains spoiler information about the solution
Could someone explain that?
scary
Whoops, not sure how I left that horrible size_t redef in there :(
I am gettng the same issue as below - all tests pass until I run suite then it comes back with
virtual void POSTFIX::TESTS(): Assertion 'to_postfix(infix) == postfix' failed.
kind of hard to debug when the even the input that fails is an unknown
Oh... yes - I think that's an open issue. Hope it's fixed soon ;)
I'm out of ideas on c++ test cases. Everything I throw at it works on my own test cases (including various ^ test cases), but I can't seem to get the hidden test cases to pass.
Time: 8ms Passed: 0 Failed: 0
solution: virtual void POSTFIX::TESTS(): Assertion `to_postfix(infix) == postfix' failed.
Sorry, I should have read the description a bit more carefully. This was my fault for jumping to the conclusion it was a binary search tree. I'm not sure if making the members public in that case would help then.
As for the error, It seems like it's not an error with your problem, but rather how codewars handles code that crashes (doesn't mark it as a failure).
Hey!
Test cases are using "equals" / "Equals" / "operator==" / JSON magic to compare the trees.
The "..." in the description (after operator==) are there on purpose, just to let people know operator== is already defined and tree comparison is valid - I'll add that to the description as well.
Which errors do you get?
Also - I set the private fields as public (like other languages) - thanks for the feedback!
Hi! This question refers to a binary tree (0-2 children), not a binary search tree
Was really hoping that submit button wouldn't have actually submited this unrelated code :(. I have no idea how to remove this submission
Feedback:
Oops. Oh well.