template<class InIt1, class InIt2>
bool equal(InIt1 first, InIt1 last, InIt2 x);
template<class InIt1, class InIt2, class Pred>
bool equal(InIt1 first, InIt1 last, InIt2 x, Pred pr);
The first template function returns true only if, for each N
in the range [0, last1 - first1)
, the predicate
*(first1 + N) == *(first2 + N)
is true. The function evaluates the predicate once, at most, for each N
.
The second template function behaves the same, except that the predicate is pr(*(first1 + N), *(first2 +
N))
.