charlie bowman wrote: > The following code works but it's awfully ugly putting a method at the > top of a script. Is this really how I have to structure a script? There seems to be a conflict of aesthetics. I tend to find it awfully ugly seeing methods strewn about an application, without being part of a class with a well-defined purpose. But, granted, the extra typing needed to define and instantiate a class may be overkill for a really small utility script. Then you'll just have to accept how the Ruby parser handles source files. Which, under other circumstances, affords you all sorts of neat behavior. Basically, Ruby is not Perl. -- James Britt http://www.ruby-doc.org - Ruby Help & Documentation http://www.artima.com/rubycs/ - The Journal By & For Rubyists http://www.rubystuff.com - The Ruby Store for Ruby Stuff http://www.30secondrule.com - Building Better Tools