**fig5_21.txt** /* 1*/ template /* 2*/ class Dynamic_Hash_Table : public Hash_Table /* 3*/ { /* 4*/ private: /* 5*/ unsigned int Num_Elements_In_Table; /* 6*/ void Rehash( ); /* 7*/ public: /* 8*/ // Constructors. /* 9*/ Dynamic_Hash_Table( unsigned int Initial_Size = Default_Size ) /*10*/ { /*11*/ Hash_Table::Hash_Table( Initial_Size ); /*12*/ Num_Elements_In_Table = 0; /*13*/ } /*14*/ // Operators. /*15*/ const Dynamic_Hash_Table & operator = /*16*/ ( const Dynamic_Hash_Table & Value ); /*17*/ // Member functions. /*18*/ virtual void Initialize_Table( ) /*19*/ { /*20*/ Hash_Table::Initialize_Table( ); /*21*/ Num_Elements_In_Table = 0; /*22*/ } /*23*/ virtual void Insert( const Element_Type & Key ); /*24*/ }; /*25*/ template /*26*/ const Dynamic_Hash_Table & /*27*/ Dynamic_Hash_Table:: /*28*/ operator =( const Dynamic_Hash_Table & Value ) /*29*/ { /*30*/ if( this != &Value ) /*31*/ { /*32*/ Hash_Table::operator= ( Value ); /*33*/ Num_Elements_In_Table = Value.Num_Elements_In_Table; /*34*/ } /*35*/ return *this; /*36*/ }