Split string's array

Hi, i have an array of strings like

arr = [“first part xxx / second part xxx”, “first part yyy / second part
yyy”]

I have to iterate over it splitting before on each string, dividing each
string in two parts, and then “re-iterate” on each part of the new
strings splitting every word of them.

like…

arr.each do |string| string=string.split("/") end

started in th right way? …how can I do?

thanks…

Hi,

arr = [“first part xxx / second part xxx”, “first part yyy / second
partyyy”]

arr.each do |i|
i.split("/").each do |j|
puts j
end
end

Stevie Ray wrote in post #1153132:

Hi, i have an array of strings like

arr = [“first part xxx / second part xxx”, “first part yyy / second part
yyy”]

arr.join(’/’).split(’/’).each { |a| a.scan(/\w+/).each {|a| p a}}