Partager via


adjacent_difference (STL/CLR)

 

The latest version of this topic can be found at adjacent_difference (STL/CLR).

Computes the successive differences between each element and its predecessor in an input range and outputs the results to a destination range or computes the result of a generalized procedure where the difference operation is replaced by another, specified binary operation.

Syntax

template<class _InIt, class _OutIt> inline  
    _OutIt adjacent_difference(_InIt _First, _InIt _Last,  
        _OutIt _Dest);  
template<class _InIt, class _OutIt, class _Fn2> inline  
    _OutIt adjacent_difference(_InIt _First, _InIt _Last,  
        _OutIt _Dest, _Fn2 _Func);  

Remarks

This function behaves the same as the STL numeric function adjacent_difference. For more information, see adjacent_difference.

Requirements

Header: <cliext/numeric>

Namespace: cliext

See Also

numeric (STL/CLR)