From: Helgitomas Gislason Date: 2007-03-10T06:58:12+09:00 Subject: "Goto line" function? Ok, I've read through the forum but I haven't got my answer. If a value in my program is true, I want my program to go back to a line like this: (Example of the program) 1. puts ' ' 2. puts ' ' 3. puts '****************************' 4. puts '** (Rules of the program) **' 5. puts '****************************' 6. puts ' ' 7. puts 'Ohh, hello there! What are you named many names?' 8. 9. names = gets.chomp 10. 11. if names == '2' 12. puts ' ' 13. puts 'Are you named two names?' 14. puts ' ' 15. answer = gets.chomp 16. if answer == 'yes' 17. (the program continues) 18. 19. BUT if answer == 'no' 20. 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? -- Posted via http://www.ruby-forum.com/.