Non-modify sequence operations
- std::all_of: The test conditions for all elements in the range
- std::any_of: Tests whether any element in the scope satisfies the criteria
- std::none_of: Tests if no element satisfies the condition
- std::for_each: Applies functionality to scope
- std::find: Finds values in the range
- std::find_if: Finds elements in the range
- std::find_if_not: Find elements in range (negative condition)
- std::find_end: Finds the last subsequence in the range
- std::find_first_of: Finds elements from a collection in scope
- std::adjacent_find: Finds equal neighbors in the range
- std::Count: The occurrence of values within the calculation range
- std::count_if: Returns the number of elements whose range meets the criteria
- std::mismatch: Returns two first positions with different ranges
- std::equal: Tests whether the elements in two ranges are equal
- std::is_permutation: Tests if the range is another permutation
- std::search: The search scope of the subsequence
- std::search_n: element
Modify a sequence operation
- std::copy: Copies the range of elements
- std::copy_n: Duplicate element
- std::copy_if: Copies some elements of the scope
- std::copy_backward: Copies the element range backwards
- std::move: Moves the range of elements
- std::move_backward: Moves the element range backwards
- std::swap: Swaps the value of two objects
- std::swap_ranges: Swaps the values of two ranges
- std::iter_swap: Swaps the value of the object that the two iterators point to
- std::transform: conversion range
- std::replace: Replace a value in the range
- std::replace_if: Replace a value in the range
- std::replace_copy: Copy range override value
- std::replace_copy_if: Copy range substitution value
- std::fill: Fills the range with a value
- std::fill_n: Fills the sequence with values
- std::generate: Generates a range value with a function
- std::generate_n: Generates sequence values with a function
- std::remove: Removes a value from the range
- std::remove_if: Removes an element from the scope
- remove_copy: The copy range is removed from the value
- remove_copy_if: Copy the range to delete the value
- std::unique: Removes consecutive duplicates in the range
- std::unique_copy: Replication scope to remove duplicates
- std::reverse: reverse range
- std::reverse_copy: Copy range reversed
- std::rotate: Rotates an element in the range to the left
- std::rotate_copy: The copy range rotates to the left
- std::random_shuffle: Randomly rearranges elements in the range
- std::shuffle: Use the generator to randomly rearrange elements in the range
Partition operations
- std::is_partitioned: Tests whether the range is partitioned
- std::p artition: The partition range is split into two
- std::stable_partition: The partition ranges to two – stable order
- partition_copy: The partition scope is divided into two
- partition_point: Obtain the partition point
sort
- std::sort: sorts the elements in the range
- std::stable_sort: Sort elements, preserve the equivalence order
- std::p artial_sort: Elements in a partially sorted range
- std::p artial_sort_copy: Copies and partially sorts ranges
- std::is_sorted: Checks if the range has been sorted
- std::is_sorted_until: Finds the first unsorted element in the range
- std::nth_element: Sort of elements in a range
Binary search (manipulation on partition ranges/sort ranges)
- std::lower_bound: Returns the iterator to the lower bound
- std::upper_bound: Returns the iterator to an upper limit
- std::equal_range: Gets the subrange of equal elements
- std::binary_search: Tests whether the values exist in sort order
Merge (operates within the sort range)
- std::merge: Merge sort ranges
- std::inplace_merge: Merges consecutive sort ranges
- std::includes: Tests whether the sort range includes another sort range
- std::set_union: The union of two sort ranges
- std::set_intersection: The intersection of two sort ranges
- std::set_difference: The difference between the two sort ranges
- std::set_symmetric_difference: The symmetrical difference between the two sort ranges
Heap operations
- std::p ush_heap: pushes elements into the heap range
- std::p op_heap: Heap-scoped pop-up element
- std::make_heap: from the range heap
- std::sort_heap: sorts heap elements
- std::is_heap: Tests whether the scope is heap or not
- std::is_heap_until: Finds the first element that is not in heap order
- std::max: Returns the maximum
- std::minmax: Returns the minimum and maximum elements
- std::min_element: Returns the smallest element in the range
- std::max_element: Returns the largest element in the range
- std::minmax_element: Returns the smallest and largest elements in the range
Other operations
- std::lexicographical_compare: lexical less than
- std::next_permutation: converts the range to the next permutation
- std::p rev_permutation: Converts the range to a previous permutation
All STL articles in C++
Considered one of the most sought-after skills in the industry, we have our own coding foundation, C++ STL, to train and master these concepts through an intense problem-solving process.