Advertisement
Garey

LevelUp

Mar 11th, 2018
337
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.17 KB | None | 0 0
  1. #include <iostream>
  2.  
  3. using namespace std;
  4.  
  5. int main() {
  6.     int a(3), b(4);
  7.  
  8.     auto sum = [&](int x, int y) -> int { return a + b; };
  9.  
  10.     cout << sum(a, b);
  11.  
  12.     return 0;
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement