-
-
Save fabiogaluppo/74e72907ac42b9c5fca1 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
initial = 0; | |
total = std::accumulate(std::begin(xs), std::begin(xs) + 6, | |
accumulator_with_predicate<int>(initial, is_even)); | |
std::cout << total << "\n"; //12 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment