Algorithms library

来自cppreference.com
< cpp


 
 
算法库
功能
Original:
Functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
修改序列操作
Original:
Non-modifying sequence operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
all_of
any_of
none_of
(C++11)
(C++11)
(C++11)
for_each
count
count_if
mismatch
equal
修改序列操作
Original:
Modifying sequence operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
分区操作
Original:
Partitioning operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
is_partitioned(C++11)
partition
partition_copy(C++11)
排序操作(排序的区间)
Original:
Sorting operations (on sorted ranges)
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
is_sorted(C++11)
is_sorted_until(C++11)
sort
二进制搜索操作(排序的区间)
Original:
Binary search operations (on sorted ranges)
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
设置操作(排序的区间)
Original:
Set operations (on sorted ranges)
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
堆的操作
Original:
Heap operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
最小/最大操作
Original:
Minimum/maximum operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
数字操作
Original:
Numeric operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
C库
Original:
C library
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
 
的算法库定义有多种用途(例如,搜索,排序,计数,操作)的操作范围的元素上的功能。请注意,其中的范围内被定义为[first, last)last是指元素“过去”的最后一个元素,检查或修改.
Original:
The algorithms library defines functions for a variety of purposes (e.g. searching, sorting, counting, manipulating) that operate on ranges of elements. Note that a range is defined as [first, last) where last refers to the element past the last element to inspect or modify.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

目录

修改序列操作
Original:
Non-modifying sequence operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Defined in header <algorithm>
(C++11)
(C++11)
(C++11)
如果一个谓词是true检查,在一定范围内的任何或没有的元素
Original:
checks if a predicate is true for all, any or none of the elements in a range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
某一范围的元素应用一个函数
Original:
applies a function to a range of elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
返回满足特定条件的元素的数量
Original:
returns the number of elements satisfying specific criteria
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
发现两个范围不同的第一位置
Original:
finds the first position where two ranges differ
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
确定如果两套的元素是相同的
Original:
determines if two sets of elements are the same
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
找到的第一个元素,满足特定的标准
Original:
finds the first element satisfying specific criteria
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
发现在一定范围内的最后一个序列中的元素
Original:
finds the last sequence of elements in a certain range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
searches for any one of a set of elements
(函数模板) [edit]
发现两个相同的(或一些其他的关系)件彼此相邻
Original:
finds two identical (or some other relationship) items adjacent to each other
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
searches for a range of elements
(函数模板) [edit]
检索数据的一些连续的范围中的一个元素的副本
Original:
searches for a number consecutive copies of an element in a range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
修改序列操作
Original:
Modifying sequence operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Defined in header <algorithm>

(C++11)
某一范围的元素复制到一个新的位置
Original:
copies a range of elements to a new location
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
(C++11)
复制到新的位置的元素数
Original:
copies a number of elements to a new location
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
份向后为了在一个范围内的元素
Original:
copies a range of elements in backwards order
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
(C++11)
某一范围的元素移动到一个新的位置
Original:
moves a range of elements to a new location
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
(C++11)
某一范围的元素移动到新的位置在向后的顺序
Original:
moves a range of elements to a new location in backwards order
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
分配一个一定值范围内的元素
Original:
assigns a range of elements a certain value
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
分配一个值,该值到的元素数
Original:
assigns a value to a number of elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
某一范围的元素应用一个函数
Original:
applies a function to a range of elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
并将结果保存在一个范围内的功能
Original:
saves the result of a function in a range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
保存N个应用程序的一个函数的结果
Original:
saves the result of N applications of a function
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
删除元素满足特定条件
Original:
removes elements satisfying specific criteria
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
复制一个范围内的元素省略了那些满足特定的条件
Original:
copies a range of elements omitting those that satisfy specific criteria
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
替换满足特定条件的所有值与另一个值
Original:
replaces all values satisfying specific criteria with another value
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
复制的范围内,更换满足特定条件的元素与另一个值
Original:
copies a range, replacing elements satisfying specific criteria with another value
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
掉期两个对象的值
Original:
swaps the values of two objects
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
交换两个范围的元素
Original:
swaps two ranges of elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
掉期两个迭代器所指向的元素
Original:
swaps the elements pointed to by two iterators
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
在一定范围内的顺序颠倒元素
Original:
reverses the order elements in a range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
是相反的范围内创建的副本
Original:
creates a copy of a range that is reversed
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
旋转的顺序在一定范围内的元素
Original:
rotates the order of elements in a range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
副本和旋转范围内的元素
Original:
copies and rotate a range of elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
随机重新排序的范围内的元素
Original:
randomly re-orders elements in a range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
removes consecutive duplicate elements in a range
(函数模板) [edit]
创建一个副本一定范围内不包含连续重复的元素
Original:
creates a copy of some range of elements that contains no consecutive duplicates
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
分区操作
Original:
Partitioning operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
(C++11)
确定的范围被划分给定的谓词
Original:
determines if the range is partitioned by the given predicate
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
把一个范围的元素分为两组
Original:
divides a range of elements into two groups
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
(C++11)
copies a range dividing the elements into two groups
(函数模板) [edit]
将元素分为两组,同时保留其相对顺序
Original:
divides elements into two groups while preserving their relative order
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
(C++11)
locates the partition point of a partitioned range
(函数模板) [edit]
排序操作(排序的区间)
Original:
Sorting operations (on sorted ranges)
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Defined in header <algorithm>
(C++11)
检查范围是否按升序排列
Original:
checks whether a range is sorted into ascending order
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
(C++11)
发现的最大的分类子范围
Original:
finds the largest sorted subrange
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
为升序排序范围
Original:
sorts a range into ascending order
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
排序第一的范围内的N个元素
Original:
sorts the first N elements of a range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
副本和部分的范围内的元素进行排序
Original:
copies and partially sorts a range of elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
排序范围内的元素,同时保持相等的元素之间的顺序
Original:
sorts a range of elements while preserving order between equal elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
部分对给定的范围内,确保它被划分给定的元素
Original:
partially sorts the given range making sure that it is partitioned by the given element
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
二进制搜索操作(排序的区间)
Original:
Binary search operations (on sorted ranges)
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Defined in header <algorithm>
返回一个迭代器的第一个元素“不低于”大于给定值
Original:
returns an iterator to the first element not less than the given value
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
返回一个迭代器的第一个元素“更大的”超过一定值
Original:
returns an iterator to the first element greater than a certain value
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
确定一个元素是否存在在一定的范围内
Original:
determines if an element exists in a certain range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
回报在一个特定的键匹配的元素
Original:
returns range of elements matching a specific key
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
设置操作(排序的区间)
Original:
Set operations (on sorted ranges)
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Defined in header <algorithm>
合并两个已排序的范围
Original:
merges two sorted ranges
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
合并两个有序的范围内的地方
Original:
merges two ordered ranges in-place
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
返回true,如果一组的一个子集的另一个
Original:
returns true if one set is a subset of another
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
计算两个集合之间的差异
Original:
computes the difference between two sets
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
计算两个集合的交集
Original:
computes the intersection of two sets
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
计算对称的两组之间的差异
Original:
computes the symmetric difference between two sets
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
computes the union of two sets
(函数模板) [edit]
堆的操作
Original:
Heap operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Defined in header <algorithm>
checks if the given range is a heap
(函数模板) [edit]
(C++11)
发现是堆的最大子区间
Original:
finds the largest subrange that is heap
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
创建一个堆出来的一个范围内的元素
Original:
creates a heap out of a range of elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
添加一个元素到一个堆
Original:
adds an element to a heap
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
从堆的最大元素中删除
Original:
removes the largest element from a heap
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
变成一个堆的排序范围内的元素
Original:
turns a heap into a sorted range of elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
最小/最大操作
Original:
Minimum/maximum operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Defined in header <algorithm>
返回较大的两个元素
Original:
returns the larger of two elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
返回最大的元素在一定范围内
Original:
returns the largest element in a range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
返回两个元素的小
Original:
returns the smaller of two elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
返回的范围内的最小元素
Original:
returns the smallest element in a range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
(C++11)
返回的较大和较小的两个元素
Original:
returns the larger and the smaller of two elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
(C++11)
返回的最小和最大的元素在一定范围内
Original:
returns the smallest and the largest element in a range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
返回true,如果一个范围是小于另一个字典
Original:
returns true if one range is lexicographically less than another
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
(C++11)
determines if a sequence is a permutation of another sequence
(函数模板) [edit]
generates the next greater lexicographic permutation of a range of elements
(函数模板) [edit]
generates the next smaller lexicographic permutation of a range of elements
(函数模板) [edit]
数字操作
Original:
Numeric operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Defined in header <numeric>
(C++11)
填充的范围内连续递增的起始值
Original:
fills a range with successive increments of the starting value
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
总结了一系列的元素
Original:
sums up a range of elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
计算的内积的2的范围内的元素
Original:
computes the inner product of two ranges of elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
计算的范围内的相邻元件之间的差异
Original:
computes the differences between adjacent elements in a range
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
计算的部分和一定范围的元素
Original:
computes the partial sum of a range of elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数模板) [edit]
C库
Original:
C library
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Defined in header <cstdlib>
排序范围内的未指定类型的元素
Original:
sorts a range of elements with unspecified type
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数) [edit]
搜索一个数组元素的类型不明确
Original:
searches an array for an element of unspecified type
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(函数) [edit]