摘要: 第五章 关联式容器 1、红黑树 operation: 左旋,右旋,变色, header实现技巧,平均查找时间复杂度nlog(n) set/map/multiset/multimap 采用RB-tree红黑树实现; 删除/插入新元素,不会导致迭代器失效; set/map不允许重复,multiset/m 阅读全文
posted @ 2020-06-28 17:00 InsistPy 阅读(124) 评论(0) 推荐(0) 编辑
摘要: stl六大组件 1.容器(containers):如vector,list,set,map,从实现角度来看stl容器是一种类模板(class template)。 2.算法(algorithms):如sort,search,copy,erase... 从实现的角度来讲stl算法是一种函数模板(fun 阅读全文
posted @ 2020-06-28 16:22 InsistPy 阅读(187) 评论(0) 推荐(0) 编辑
隐藏