replace(beg, end, old_val, new_val);
Replace elements whose value is equal to old_val
with new_val
in iterator range [beg, end)
.
replace_if(beg, end, pred, new_val);
Replace elements whose return value is nonzero when calling predicate pred(val)
with new_val
in iterator range [beg, end)
.
replace_copy(beg, end, dest, old_val, new_val);
Copy elements in iterator range [beg, end)
to iterator dest
, and replace elements whose values are equal to old_val
with new_val
.
replace_copy_if(beg, end, dest, pred, new_val);
Copy elements in iterator range [beg, end)
to iterator dest
, and replace elements whose return value is nonzero when calling predicate pred(val)
with new_val
.