From: Peter Szinek Date: 2006-10-20T00:08:10+09:00 Subject: Re: array trouble Gijs Nijholt wrote: > Hi > > I want to add a value to an arrays' values like this: > > ret = "" > "abcd".to_a.each do |w| > ret += " " > end > > this gives => "abcd" in IRB > but I expected it to give "a b c d " How about "abcd".split('').join(' ') Peter http://www.rubyrailways.com