こうかなあ?

f = proc do|e|
 if e.is_a? Array
  e.each do |e|
   f.call e
  end
 else
  puts e
 end
end

arr.each do|e|
 f.call e
end