**fig8_6.txt** /* 1*/ static const Default_Size = 10; /* 2*/ class Disj_Sets /* 3*/ { /* 4*/ private: /* 5*/ int *S_Array; /* 6*/ int S_Size; /* 7*/ Disj_Sets( Disj_Sets const & Value ); // Disabled. /* 8*/ public: /* 9*/ // Constructor. /*10*/ Disj_Sets( unsigned int Num_Elements = Default_Size ); /*11*/ // Destructor. /*12*/ ~Disj_Sets( ) { delete [ ] S_Array; } /*13*/ // Operator. /*14*/ const Disj_Sets & operator = ( Disj_Sets const & Value ); /*15*/ // Member functions. /*16*/ // The basic routines. /*17*/ void Set_Union( unsigned int Root1, unsigned int Root2 ); /*18*/ unsigned int Find( unsigned int X ); /*19*/ // The improved routines. /*20*/ void Union_By_Height( unsigned int Root1, /*21*/ unsigned int Root2 ); /*22*/ unsigned int Find_And_Compress( unsigned int X ); /*23*/ };