From: Clemens Hintze Date: 2002-03-27T04:27:38+09:00 Subject: Re: Difference between 'do' and 'begin' In james@rubyxml.com writes: > > -----Original Message----- > > From: Clemens Hintze [mailto:c.hintze@gmx.net] (...) > However, both Ruby in a Nutshell and the Pickaxe book refer to > begin/end as blocks. So, is it incorrect to refer to > begin > # some code > end > as a block? Oops! I had not recognized this ... > Or is it block, but not the same sort of block as: I would not call it a block. In one of the replies it was called compound statement. I think this sounds not too bad! If I had the task to invent a name, I would try to find a name for e.g. the 'block' executed within a while-statement: while end and name the statements between 'begin' ... 'end' the same. Especially as I can also use 'begin' ... 'end' to form a loop similar to a 'while' ... 'end': begin end while So I would think, they should named similar here ... Just my 0.02Euro Ciao, \cle -- Clemens Hintze mailto: c.hintze@gmx.net