From: Cyril Joe Date: 2011-04-08T01:38:08+09:00 Subject: newlines in array problem Is there a way to get rid of newlines in an array? Example: array = ["hel\nlo", "bl\nah"] I want the output to be new_array = ["hello", "blah"] I tried: array.each do |el| el.delete("\n") end But that didn't work. Can't figure this out. Any suggestions? -- Posted via http://www.ruby-forum.com/.