Implementando Weighted Quick Union vs Quick Union
Testado performance com 100k elementos:

$ ruby client.rb quick_union
Processing QuickUnion
       user     system      total        real
  28.370000   0.010000  28.380000 ( 28.405957)

$ ruby client.rb weighted_quick_union
Processing WeightedQuickUnion
       user     system      total        real
   0.210000   0.000000   0.210000 (  0.216753)