Open
Description
Extrema algorithms (min_element/max_element/minmax_element) have specific semantics in case of repeated values. The existing unit tests don't cover these, as they only use random_iota
as the input range. In particular:
min_element
is required to return the first min value,max_element
is required to return the first max value,minmax_element
is required to return the first min value and the last max value.
Tests for these cases should be added, and the implementations adjusted as needed.