You are viewing a single comment's thread. Return to all comments →
I used a loop with a deque as a stack instead to get around that problem
I used a loop with a deque as a queue too but it didn't get around that problem with that solution
You can use even the list() and it works. See the "Iterative InOrder traversal" example:
here on wiki
Interesting... can you explain briefly how you used a deque to get around the problem.