We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b002dcd commit ada7183Copy full SHA for ada7183
06-Stack-and-Queue/Course Code (C++)/03-Non-Recursive-Implementation-of-a-Recursive-Algorithm/main3.cpp
@@ -16,13 +16,15 @@ struct TreeNode {
16
TreeNode(int x) : val(x), left(NULL), right(NULL) {}
17
};
18
19
-struct Command{
20
- string s; // go, print
21
- TreeNode* node;
22
- Command(string s, TreeNode* node): s(s), node(node){}
23
-};
24
-
25
class Solution {
+
+private:
+ struct Command{
+ string s; // go, print
+ TreeNode* node;
+ Command(string s, TreeNode* node): s(s), node(node){}
26
+ };
27
28
public:
29
vector<int> postorderTraversal(TreeNode* root) {
30
0 commit comments