lib: Enhanced DisjointSet data structure
authorAlexandre Blondin Massé <alexandre.blondin.masse@gmail.com>
Sun, 16 Nov 2014 03:40:56 +0000 (22:40 -0500)
committerAlexandre Blondin Massé <alexandre.blondin.masse@gmail.com>
Mon, 17 Nov 2014 00:09:18 +0000 (19:09 -0500)
commitb67da8c2df63756764b002362a4457ca10cd58d1
treedc7f9eea874ea2310d258dbd2de2baf03ba26537
parent882fcae5becc7842e0d8b1f812703ad9f31f1c93
lib: Enhanced DisjointSet data structure

It is now possible to retrieve the number of subsets in the partition by
using the 'number_of_subsets' property. It is useful for instance when
one wants to know if the partition is a singleton, or if it is trivial
(every element is alone in its subset).

Signed-off-by: Alexandre Blondin Massé <alexandre.blondin.masse@gmail.com>
lib/standard/collection/union_find.nit