Q. What is a block in Ruby?

  • (A) A chunk of code that can be passed to methods as an argument
  • (B) A data structure for storing multiple values
  • (C) A special type of object that holds code to be executed
  • (D) A method that can be invoked with different arguments
πŸ’¬ Discuss
βœ… Correct Answer: (A) A chunk of code that can be passed to methods as an argument

You must be Logged in to update hint/solution

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
296467
Total Visits
πŸ“½οΈ
3 y ago
Published
πŸŽ–οΈ
Mr. Dubey
Publisher
πŸ“ˆ
84%
Success Rate