3 ms·
I encountered this data structure over 20 years ago as an undergraduate, but didn't recognise that it was the same structure used in Kruskal's algorithm until I
by chalst 15y ago
I encountered this data structure over 20 years ago as an undergraduate, but didn't recognise that it was the same structure used in Kruskal's algorithm until I read this.
The time complexity of the path-compressed algorithm is very nice.