Skip to main content
Journey Uncommon Logo
JourneyUncommon
mediumRubyProc vs lambda usageSingle-choice MCQ

Using proc composition, what does `(f >> g).call(3)` produce for `f = ->(x){x+1}` and `g = ->(x){x*2}`?

f = ->(x) { x + 1 } g = ->(x) { x * 2 } (f >> g).call(3) # => ? (f << g).call(3) # => 7