You are viewing a single comment's thread. Return to all comments →
Hey there. Can you please explain the difference between Node and Leaf? Especially in this part:
if (childHasChild) { tree = new TreeNode(values[treeNum - 1], colors[treeNum - 1], parent.getDepth() + 1); } else { tree = new TreeLeaf(values[treeNum - 1], colors[treeNum - 1], parent.getDepth() + 1); }
Seems like cookies are disabled on this browser, please enable them to open this website
Java Visitor Pattern
You are viewing a single comment's thread. Return to all comments →
Hey there. Can you please explain the difference between Node and Leaf? Especially in this part: