0001 template <typename K, typename V> struct Dictionary { //词典Dictionary模板类 0002 virtual int size() const = 0; //当前词条总数 0003 virtual bool put ( K, V ) = 0; //插入词条(禁止雷同词条时可能失败) 0004 virtual V* get ( K k ) = 0; //读取词条 0005 virtual bool remove ( K k ) = 0; //删除词条 0006 };