Use VECTOR_FIND_IF and VECTOR_FOR_EACH instead of manual loops