Home / MCQ Bank / Computer
Computer Methods In Ruby

In Ruby, what does the `yield` keyword do in a method?

Select the best option to verify your answer:
Show Correct Answer
Correct Answer: Option B • Calls the block passed to the method

Related Computer Questions

Which concept in C++ allows a class to have multiple functions with the same name but different parameter lists? What will be the output of the following C# code? static void Main(string[] args) { float i = 1.0f, j = 0.05f; do { Console.WriteLine(i++ - ++j); }while (i < 2.0f && j <= 2.0f); Console.ReadLine(); } How do you read a character from a file in C? In data preprocessing, what is the purpose of data scaling or normalization? What is the purpose of the `instanceof` operator in Java?