algorithm常用函数:("#"有该函数的实现)
非修改性序列操作 :
for_each遍历
is_permutation 是否是同一个排列,判断两个集合是否含有相同的元素#
修改性的序列操作 :
replace,replace_if,replace_copy,replace_copy_if
unique 去除相邻重复元素
reverse(t1.begin(),t1.end());//反转
rotate(t1.begin(),t1.begin()+4,t1.end());//循环移动
shuffle,random_shuffle 随机移动元素
划分:
sort#
二叉树:
归并(已排序集合):
set_union,set_intersection,set_difference合集、交集、差集#
堆:
make_heap,push_heap,pop_heap,sort_heap(以最大的K个数为例)
其他:
正在整理中......