From: "Kevin Börgens" Date: 2004-11-11T07:53:30+09:00 Subject: Re: array.each restart when array is changed Kevin B�rgens wrote: > Hi! > > > How to restart a "each" iteration when the iterated array is changed? I do > it like this > > changed=false > while (changed) > changed=false > array.each {|e| > if (today_is_christmas) > array=array+=["Hello santa claus"] > changed=true > end > } As I re-read my post, I find it a bit ambituous. It is not important that directly after the change the iteration is restarted, it is sufficient when it is restarted when the iteration finishes (like in the above example) TIA, Kevin