Re: Hard to visualize this statement
- From: "Jacky" <jl@xxxxxxxxxx>
- Date: Mon, 29 Jan 2007 22:03:55 +0800
"Igor Tandetnik" <itandetnik@xxxxxxxx> ¼¶¼g©ó¶l¥ó·s»D:%23jqxU16QHHA.4832@xxxxxxxxxxxxxxxxxxxxxxx
"Jacky" <jl@xxxxxxxxxx> wrote in messageDear Igor,
news:%23daaXs6QHHA.3412@xxxxxxxxxxxxxxxxxxxx
Queue< complex<double> > qc;
I am confused about this data structure, can anyone explain that?
Queue is a template class taking one template parameter. It is
instantiated with the class complex<double> as the value of this
parameter. complex<double> is itself a template instantiation. All in all,
the situation is not much different than, say, calling one function with
the result of another, as in f(g(x)) .
In this particular case, complex<double> is a complex number using fields
of type double for its real and imaginary parts. I'm not sure what Queue
is, but if it's similar to std::queue, Queue< complex<double>
is a queue data structure holding elements of type complex<double>.
Thanks for your reply. But I want to see some code in action (some practical
examples)
Thanks once again
Jacky
--
With best wishes,
Igor Tandetnik
With sufficient thrust, pigs fly just fine. However, this is not
necessarily a good idea. It is hard to be sure where they are going to
land, and it could be dangerous sitting under them as they fly
overhead. -- RFC 1925
.
- Follow-Ups:
- Re: Hard to visualize this statement
- From: Igor Tandetnik
- Re: Hard to visualize this statement
- References:
- Hard to visualize this statement
- From: Jacky
- Re: Hard to visualize this statement
- From: Igor Tandetnik
- Hard to visualize this statement
- Prev by Date: Re: Hard to visualize this statement
- Next by Date: Re: Finding either of two elements in a list
- Previous by thread: Re: Hard to visualize this statement
- Next by thread: Re: Hard to visualize this statement
- Index(es):
Relevant Pages
|