We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0580fff commit 5a5d3a0Copy full SHA for 5a5d3a0
1 file changed
src/main/java/com/thealgorithms/datastructures/disjointsetunion/DisjointSetUnion.java
@@ -32,7 +32,7 @@ public Node<T> makeSet(final T value) {
32
*/
33
public Node<T> findSet(Node<T> node) {
34
if (node != node.parent) {
35
- node.parent = findSet(node.parent); // Path compression
+ node.parent = findSet(node.parent);
36
}
37
return node.parent;
38
0 commit comments