Int stored in the Bag. Last week we would have suggested creating a FindMaxVisitor class and a FindMinVisitor class to accomplish such a feat. This will get the job done, but it would be better to use Iterators. Let's create them now. One Iterator could be moving forward and backward.
Associations have two data members, key and value .
These values are set in the Constructors. Associations have two constructors. One that only takes in a key and other takes in both members. The functions for this class are simple. There is a Key function and a Value function.