Boost logo

Boost :

From: Daniel Frey (daniel.frey_at_[hidden])
Date: 2001-06-07 09:15:09


nbecker_at_[hidden] wrote:
>
> This seem to be an obvious addition. It is not present in current
> library that is part of gcc, at least.
>
> template<typename T>
> ostream& operator<< (ostream& os, const complex<T>& z) {
> os << '(' << real (z) << ',' << imag (z) << ')';
> return os;
> }

How about:

   os << '(' << real(z) << '+' << imag(z) << "i)";

Regards, Daniel

--
Daniel Frey
aixigo AG - financial training, research and technology
Schloß-Rahe-Straße 15, 52072 Aachen, Germany
fon: +49 (0)241 936737-42, fax: +49 (0)241 936737-99
eMail: daniel.frey_at_[hidden], web: http://www.aixigo.de

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