boost error

closed account (jwkNwA7f)
I am having an error on lines 8, 12:

1
2
3
4
5
6
7
8
9
10
11
12
13
#include </Users/retsgorf/Downloads/boost_1_54_0/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) << " " );
}


It says:
Xcode wrote:
Use of undeclared identifier 'boost'

and
Xcode wrote:
Use of undeclared identifier '_1'


This is the example in the book, so I think it should work.

Thank you!

EDIT: Oh, Line 1 should be the problem. I have no idea why I thought that would work.
Last edited on
Topic archived. No new replies allowed.