Container‐based version of the <numeric> std::adjacent_difference() function to compute the difference between each element and the one preceding it and write it to an iterator.
Synopsis
Declared in <absl/algorithm/container.h>
template<
typename InputSequence,
typename OutputIt>
constexpr
OutputIt
c_adjacent_difference(
InputSequence const& input,
OutputIt output_first);
Return Value
An iterator to the end of the written range in the output.
Parameters
Name |
Description |
input |
The container whose elements to process. |
output_first |
The output iterator receiving the differences. |
Created with MrDocs