Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // c++ -fpic -std=c++11 function.cpp -o function
- #include<vector>
- #include<iostream>
- using namespace std;
- int main()
- {
- auto func = [](int m, int x, vector<int> j){for (auto &c : j) cout<<"Y: "<<(m*x)+c<<"\n";};
- func(5, 3, {1,2,3,4,5});
- return 0;
- }
Add Comment
Please, Sign In to add comment