Skip to content

Instantly share code, notes, and snippets.

@abcsharp
Created October 9, 2011 16:58
Show Gist options
  • Save abcsharp/1273910 to your computer and use it in GitHub Desktop.
Save abcsharp/1273910 to your computer and use it in GitHub Desktop.
なんかよくわからないけど突発的にC++11のラムダ式を乱用してみた
#include <functional>
#include <iostream>
int main(void)
{
auto Func=[](int a){
return [=](int b){
return [=](int c){
return a+b+c;
};
};
};
std::cout<<Func(10)(20)(30);
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment