Q. How do you define a lambda in Ruby?

  • (A) By using the create_lambda function
  • (B) By defining a method with the keyword lambda
  • (C) Using the lambda keyword followed by curly braces {}
  • (D) By using the -> (stabby lambda) syntax
πŸ’¬ Discuss
βœ… Correct Answer: (D) By using the -> (stabby lambda) syntax

You must be Logged in to update hint/solution

πŸ’¬ Discussion


πŸ“Š Question Analytics

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