#include #include #include #include int main() { std::vector a{1,2,3,4}; std::vector b{5,6,7,8}; // result vector std::vector c(a.size(), 0); // double std::for_each(a.begin(), a.end(), [](int &n){ n*=2;}); std::cout << "Double:" << std::endl; for (auto const &i: a){ std::cout<()); int mult = std::accumulate(a.begin(), a.end(), 1, [](int a, int b)->int { return a * b; }); std::cout << "Sum: " << sum << "\nDiff from 15: " << diff << "\nProd: " << mult << std::endl; return 0; }