NonModifying algorithms change neither the order nor the order nor the value of the elements they process.These algorithms operate with input
and forward iterators .We can call them for all standard containers
Table
Name | Effect | Link |
for_each | Performs an operation for each element | |
count | Returns number of element | Example and Description |
count_if | Returns number of element which match the criteria | Example and Description |
min_element | Returns the element with smallest value | Example and Description |
max_element | Returns the element with Highest value | Example and Description |
minmax_element | Returns the element with smallest and Highest Value | Example and Description |
find | finds the first element | Example and Description |
find_if | finds the first element satisfying specific criteria | Example and Description |
find_if_not | finds the first element satisfying specific criteria | Example and Description |
search_n | Search First N Matching Consecutive Elements | Example and Description |
search | Search First Sub range | Example and Description |
find_end | Search Last Sub range | Example and Description |
find_first_of | Search First of Several Possible Elements | Example and Description |
adjacent_find | Search Two Adjacent , Equal Elements | Example and Description |
equal | Testing equality | Example and Description |
is_permutation | Testing for UnOrdered Equality | Example and Description |
mismatch | Search the First Difference | Example and Description |
lexicographical_compare | Testing for Less than | Example and Description |
is_sorted | checks whether a range is sorted into ascending order | Example and Description |
is_sorted_until | finds the largest sorted sub range | Example and Description |
is_partitioned | determines if the range is partitioned by the given predicate | Example and Description |
partition_point | divides a range of elements into two groups | Example and Description |
is_heap | Check for Being a Heap (Maximum Elements First) | Example and Description |
is_heap_until | finds the largest sub range that is a max heap | Example and Description |
all_of,any_of,none_of | checks if a predicate is true for all, any or none of the elements in a range | Example and Description |