modify_if function

Selectively Modify Elements of a Vector