I like the idea of loops that sound like English.  I want to make them as
simple as possible.  I am currently thinking of this:

1) First introduce :
3.times do
   ...
end

This is the simplest loops possible, and the most like English.

2) Next do conditionals:
if  cond
   ...
end

3) Now, with the background of conditionals, move on to 'while':
while  cond
   ...
end


I will *not* use the word 'block', or 'iterator'.  I will not show this
example:
3.times do |var|
   ...
end

I will just tell them that this is a loop that blindly does the stuff
inside 3 times.  No mention of iterators or blocks or anything else.  I
think it's a great introduction to loops.

What do you think?

Daniel.


> Yes, if it's 'while true'.  However:
>
>   while (number < 400)
>     puts 'Still too small...'
>     number = number * 2
>   end
>
> ...seems almost like english.  "While the number is less than 400, write out
> 'Still too small...', and then..."
>
> When would you ever use the phrase 'loop do' in a sentence?  Maybe 'loop
> doing', or 'In the loop, do...'
>
> Even so, I *really* want to avoid the 'do' until after blocks have been
> well-explained.  That bit me time and time again.  Am I the only one this
> happened to?
>
> If so, then I will think about it some more... no promises, though.  :)
>
> Chris