On Tue, Mar 20, 2001 at 06:18:11PM +0100, Lars Gullik Bjønnes wrote:
> Depends.... _I_ thing my version is better than your since it operates
> on iterators, so I don't have to copy the whole vector.
> This is also why I thing the back_inserter variant is better than the
> transform solution.
But when you use a back_inserter, the vector will resize from time to time
and the elements will be copied.
> It is also nice to use std::functors as building stones.
>
> And it also seems that you solution will have to copy the elements in
> the vector a couple od times more than the other solutions.
Due to the above, I don't think this is the case.
Anyway, performance issues are probably not very important here.