Ruby - Functional Patterns in Ruby
What is the output of this Ruby code?
p1 = Proc.new { |x| x + 2 }
p2 = Proc.new { |y| y * 3 }
combined = p1 >> p2
puts combined.call(4)