From: Johannes Ahl-mann Date: 2005-02-13T10:15:04+09:00 Subject: Re: difficulty with blocks > That works fine, but let me ask you what you're trying to do? > There're certainly much more natural ways to get a Fibonacci > abstracted in Ruby -and this is not said maliciously in any way; > it'd just be a lot easier to advise if we knew the goal, which > I assume may not be abstracting the FibSeq but to work out a > certain idiom? :) i am really just trying to come up to speed in ruby. i was wondering how a natural idiom for "separating mechanism and policy" would look in python. in another post someone wrote a really short version using "break" in a block... i didn't know this was possible and is pretty much what i was looking for. the world of internal iterators is just a little different from the external ones in python. but after spending a little more time with ruby, finding the Generator module and being told that you can "break" within a module (although i haven't quite grasped how that fits in with the closure concept!?) i am a lot more comfortable with internal iterators... idioms take a long to time to learn, comprehend and apply... thx, Johannes