Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2004-03-09 08:50:38


> | > transform(v.begin(), v.vend(), v.begin()
> | > (auto x) ((int y) auto { return y + x; }) (i));
> | >
> |
> |
> | Yes, but this is a quite complex and hard to read way to express
> | something simpler.

Yeah, the corresponding lambda in Python is:

      labmbda x,y: x+y

It'd be nice if we could get to something that simple.

-- 
Dave Abrahams
Boost Consulting
www.boost-consulting.com

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk