goto.line.7 (And skip the rules, just restart it and begin
from line 7.)
What is the command? I know it’s not “goto.line.X” but what is it? “back
to line.X”? “goto.lineX”? What is the command?
Addressing just the loop/goto issue, how about summat like:
#!/usr/bin/env ruby
done=false
until done
puts ’ ’
puts ’ ’
puts ‘’
puts ‘** (Rules of the program) **’
puts '’
puts ’ ’
puts ‘Ohh, hello there! What are you named many names?’
names = gets.chomp
if names == ‘2’
puts ’ ’
puts ‘Are you named two names?’
puts ’ ’
answer = gets.chomp
done = true if answer == ‘yes’
end
end #This is where “the program continues”
puts ‘the end’
This gives me the output:
lnx:scratch : blah.rb
** (Rules of the program) **
Ohh, hello there! What are you named many names?
2
Are you named two names?
no
** (Rules of the program) **
Ohh, hello there! What are you named many names?
2