> > h = {} > > File.foreach("fred.ini") do |line| > > key, value = line.chomp.split("=") > > h[key] = value > > end > > > > > > Ross > > > Thank you! This is clear and still concise. The other responses > seem > to gravitate towards Perl-like one-liners. But this defeats the > purpose of writing in Ruby---to avoid Perl obfuscations. The above > is > much more readable and also much more idiomatic than many of the > others. This should go into athe Ruby Cookbook (if it were still > up). Well said; I found this to be the best balanced between rubyish and still readable. > ===== -- Yahoo IM: michael_s_campbell __________________________________________________ Do you Yahoo!? Yahoo! Mail Plus Powerful. Affordable. Sign up now. http://mailplus.yahoo.com