in reply to foreach loop question

dda,
I have been monitoring this thread for most of the day and as far as I can tell, no one has stated the obvious.

You would have (or could create) an infinite loop.

Cheers - L~R

Update: As fletcher_the_dog pointed this behavior does create the infinite loop for an array (not hash), and as pointed out by Mr. Muskrat that this is a known deficiency and it should be avoided.

Replies are listed 'Best First'.
Re: Re: foreach loop question
by dws (Chancellor) on Apr 17, 2003 at 00:32 UTC
    I have been monitoring this thread for most of the day and as far as I can tell, no one has stated the obvious.

    There is such a thing as letting people discover their next problem. If we solve it for them before they encounter it, how will they learn?