Created
October 9, 2011 16:58
-
-
Save abcsharp/1273910 to your computer and use it in GitHub Desktop.
なんかよくわからないけど突発的にC++11のラムダ式を乱用してみた
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#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