[#absl-c_adjacent_difference-08]
= xref:absl.adoc[absl]::c&lowbar;adjacent&lowbar;difference
:relfileprefix: ../
:mrdocs:

Container&hyphen;based version of the &lt;numeric&gt; `std&colon;&colon;adjacent&lowbar;difference()` function to compute the difference between each element and the one preceding it and write it to an iterator&period;

== Synopsis

Declared in `&lt;absl&sol;algorithm&sol;container&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;
    typename InputSequence,
    typename OutputIt&gt;
constexpr
OutputIt
c&lowbar;adjacent&lowbar;difference(
    InputSequence const& input,
    OutputIt output&lowbar;first);
----

== Return Value

An iterator to the end of the written range in the output&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *input*
| The container whose elements to process&period;
| *output&lowbar;first*
| The output iterator receiving the differences&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
