Nicolas Alvarez <nic### [at] gmail com> wrote:
> for (std::vector<int>::const_iterator i = someList.begin(); i !=
> someList.end(); ++i) {
> total += *i;
> }
Maybe not the best of examples because with the next C++ standard you
will also be able to do it like:
for(auto i = someList.begin(); i != someList.end(); ++i)
total += *i;
which is not enormously longer than the lambda version.
--
- Warp
Post a reply to this message
|