Ruby - Blocks, Procs, and Lambdas
What is the output of this Ruby code?
my_proc = proc { |x| x * 2 }
puts my_proc.call(7)my_proc = proc { |x| x * 2 }
puts my_proc.call(7)15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions