CIS 11: Data Structures and Algorithms

Project B

Complete Project 8 from Chapter 3 of the text. Directions are on page 142.

typedef double value_type;
keyed_bag();
void insert(const value_type& entry, int key);
bool erase(int key);
value_type get(int key) const;
size_type size() const;
size_type count(const value_type& target) const;
bool has_key(int key) const;

When you're satisfied with the definition and implementation, submit your work via the CATE form for Project B.

Legend: method/function keyword literal

2007/02/23