Thomas B. wrote:
> Clinton D. Judy wrote:
>> Sometimes I open a parentheses without closing it, or a DO without an
>> END, or a { without a }... Once you get the hang of Ruby's pretty loose
>> syntax, you'll also realize you forgot to close something. That's not
>> what you did in the screenshot, but I'm warning you for next time. ;-) I
>> forget to do that all the time.
>> 
>> If all else fails, I hit CTRL+C, but I don't know if that causes
>> problems. Someone have a better understanding?
> 
> Your exit is not really executed, because as you see, you are without 
> some nesting (the 3 in 009:3> tells you you're in sine three things, 
> like three classes or methods or something). You must first go out of 
> all things you're in by typing end in each line (or closing brackets). 
> Usually when you do a mistake, just type end and press enter until you 
> see the prompt ends with NNN:0> again (there might be some error message 
> too, just ignore it), and then your exit or anything else will work.
> 
> But for testing, just write a separate program! You won't have to repeat 
> everything in case of a mistake every time. Here is something about 
> writing separate programs: 
> http://al2o3-cr.blogspot.com/2008/08/second-step.html
> 
> TPR.

The problem was that I didn't type end.  I feel very stupid now.  Thanks 
for the help all!

Also found that CTRL+D works.  Is this a coincidence that CTRL+C and 
CTRL+D both work?

Cheers!

Scott
-- 
Posted via http://www.ruby-forum.com/.