Boost logo

Boost Users :

Subject: [Boost-users] Using lamdba for vector of array initialization
From: Alexander Khomyak (Alexander.Khomyak_at_[hidden])
Date: 2011-06-09 02:30:09



I have vector of boost array:


typedef boost::array<char, 10> array10;

typedef std::vector<array10> vector_of_array10;

vector_of_array10 v;



Now I initialize it using for statement:


for(vector_of_array10::iterator i = v.begin(); i != v.end(); ++i)

      (*i)[0] = '\0';


How can I do the same initialization using lambda expression and

In advance thank you very much for the tip.


Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at