Vidyalelo
Ruby Programming · Q19

Blocks and Procs in Ruby

Programming · Ruby Programming · question 19

Q19

What does the yield keyword do in Ruby?

A.
Executes the block passed to the method
Answer
B.
Returns the value of the block passed to the method
C.
Exits the method and returns to the caller
D.
None of the above

Answer: Option A

Solution

Answer: Option A
No explanation is given for this question Let's Discuss on Board