Kent Johnson wrote:
> Bob Gailer wrote:
>> Asrarahmed Kadri wrote:
>>>
>>> What are generators and iterators...??And why are they are needed..??
>>>
>>> I can do my stuff with a 'for' or a 'while' loop.. so why do I need an
>>> ITERATOR..?
>> iterators & generators do not replace while or for
> My understanding is that an iterator is basically a facade` pattern.
> If you aren't familiar with patterns, a facade` pattern basically makes
> something really easy to use or convenient. Yes, you can "do it by
> hand", and many times that is indeed the preferred method, but sometimes
> it'
My understanding is that an iterator is basically a facade` pattern. If
you aren't familiar with patterns, a facade` pattern basically makes
something really easy to use or convenient. Yes, you can "do it by
hand", and many times that is indeed the preferred method, but sometimes
it's easier
> What are generators and iterators...??And why are they are needed..??
>
> I can do my stuff with a 'for' or a 'while' loop.. so why do I need an
> ITERATOR..?
>
> And what is a generator ..? I did try to read about these two things on the
> web, but still I AM CONFUSED.
here are some more place
D] On
Behalf Of Bob Gailer
Sent: Friday, October 27, 2006 10:11 AM
To: Asrarahmed Kadri
Cc: pythontutor
Subject: Re: [Tutor] I am terribly confused about "generators" and
"iterators".. Help me
Asrarahmed Kadri wrote:
>
>
> Hi Folks,
>
> What are generator
Bob Gailer wrote:
> Asrarahmed Kadri wrote:
>>
>> What are generators and iterators...??And why are they are needed..??
>>
>> I can do my stuff with a 'for' or a 'while' loop.. so why do I need an
>> ITERATOR..?
> iterators & generators do not replace while or for loops!
No, actually iterato
Asrarahmed Kadri wrote:
>
>
> Hi Folks,
>
> What are generators and iterators...??And why are they are needed..??
>
> I can do my stuff with a 'for' or a 'while' loop.. so why do I need an
> ITERATOR..?
iterators & generators do not replace while or for loops!
>
> And what is a generato
Hi Folks,
What are generators and iterators...??And why are they are needed..??
I can do my stuff with a 'for' or a 'while' loop.. so why do I need an ITERATOR..?
And what is a generator ..? I did try to read about these two things on the web, but still I AM CONFUSED.
To be honest, I am