From: "David A. Black" Date: 2010-09-12T05:28:31+09:00 Subject: Re: Why does my program exit?! Hi -- On Sun, 12 Sep 2010, Tim Romberg wrote: > David A. Black wrote: >> Hi -- >> >> On Sun, 12 Sep 2010, Tim Romberg wrote: >> >>> Hi I was hoping that anyone could help me with this piece of code from >>> my program?! I have a menu with 2 submenus that you can reach from the >>> main menu. When I start the program I want the main menu to be presented >>> with a number of choices. My program is based on user input so naturally >>> when you enter the program you should be able to do the choices that are >>> presented in the menus. It worked before but now when I started adding >>> features for it(its for an assignment for a course) now it just presents >>> the menu and then exits the program. Can anyone help me with this. I >>> will post the code below and hopefully someone with more programming >>> skills than me can see the problem. Thanks! >> >> Let me turn the question around: why would you expect it not to exit? At >> what point are you telling it to wait for user input? > > Yes I know. I just were not sure how to incorporate the user input in a > good way. Do you have any tips?! Several, but I'm a bit skittish about directly answering questions that are for homework assignments without knowing the details a little more (whether it's for a grade, etc.). Chalk it up to my many years as a professor :-) David -- David A. Black, Senior Developer, Cyrus Innovation Inc. The Ruby training with Black/Brown/McAnally Compleat Philadelphia, PA, October 1-2, 2010 Rubyist http://www.compleatrubyist.com