Go back to Richel Bilderbeek's homepage.
Go back to Richel Bilderbeek's C++ page.
Math code snippet to add two to all elements in a container.
There are multiple ways to implement AddTwo:
This is the anwer of exercise #9: No for-loops #1.
#include <vector> |
#include <algorithm> |
Prefer algorithms over loops [1][2].
#include <vector> |
Go back to Richel Bilderbeek's C++ page.
Go back to Richel Bilderbeek's homepage.