Q. In Ruby, what is the difference between a proc and a lambda?

  • (A) Procs perform strict argument checking, while lambdas do not
  • (B) Lambdas can accept a variable number of arguments, while procs cannot
  • (C) Lambdas perform strict argument checking, while procs do not
  • (D) Procs can accept a variable number of arguments, while lambdas cannot
πŸ’¬ Discuss
βœ… Correct Answer: (C) Lambdas perform strict argument checking, while procs do not

You must be Logged in to update hint/solution

πŸ’¬ Discussion


πŸ“Š Question Analytics

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