Skip to content

Commit e512958

Browse files
committed
Update BoundaryTraversal.java
1 parent 7bbcc8b commit e512958

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/com/thealgorithms/datastructures/trees/BoundaryTraversal.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ private static void addRightBoundary(BinaryTree.Node node, List<Integer> result)
116116

117117
// Checks if a node is a leaf node
118118
private static boolean isLeaf(BinaryTree.Node node) {
119-
return (node.left == null && node.right == null);
119+
return node.left == null && node.right == null;
120120
}
121121

122122
// Iterative boundary traversal

0 commit comments

Comments
 (0)