Boost logo

Boost Users :

From: Jonathan Turkanis (technews_at_[hidden])
Date: 2005-03-04 21:33:04


me22 wrote:
> On Fri, 04 Mar 2005 16:59:12 -0500, Jason House <jhouse_at_[hidden]>
> wrote:
>> "In a nutshell" one can do the following:
>> for_each(a.begin(), a.end(), std::cout << _1 << ' ');
>>
>> (where a is something like std::list<int>)
>
> You can cout the contents of container a with spaces between using:
> copy( a.begin(), a.end(), ostream_iterator< a::value_type >( cout, '
> ' ) );
>
> No boost required. Hopefully someone with more boost experience can
> give an elegant solution for a more general case ( such as your map<
> string, list<int> > ).

You can try this:

http://www.kangaroologic.com/format_lite/

Jonathan


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net