Last active
September 15, 2018 04:32
-
-
Save mochow13/9231f57f7cee48fce6357f2f07f70c7d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
std::vector<int> collection={1,2,0,5,0,3,4}; | |
// itr contains the iterator to the first element following the specific property | |
auto itr = std::find_if(begin(collection), end(collection), [](int x) { | |
return x%2==0; // the property | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment