
22 Feb
2006
22 Feb
'06
4:58 p.m.
I have a for loop which pass the map.second to a function, like this: class A; typedef map<int, A*> MyMap; sortY(A& a); for (MyMap::iterator iter = map.begin(); iter != map.end(); ++iter) { A *a = (*iter).second; sortY(*a); } how can I translate the above for() loop into for_each and use boost lambda? __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com