@jc
多謝指點,不過對于bjam的install 命令不是很了解,還請詳說
@sunoom
就象樓上說的那個格式,這是在網上找到的代碼:
#include <boost/lambda/lambda.hpp>
#include <iostream>
#include <iterator>
#include <algorithm>
int main()
{
using namespace boost::lambda;
typedef std::istream_iterator<int> in;
std::for_each(
in(std::cin), in(), std::cout << (_1 * 3) << " " );
}
運行后輸入1 2 3 結果為3 6 9