Q. In lambda expression `(a, b) -> a + b`, what is required of 'a' and 'b'?

  • (A) Both must be final
  • (B) Both must be of the same type
  • (C) Both must be numbers
  • (D) Both must be parameters of the same functional interface method
πŸ’¬ Discuss
βœ… Correct Answer: (D) Both must be parameters of the same functional interface method
Explanation: The parameters must match the functional interface method signature.
Explanation by: Mr. Dubey
The parameters must match the functional interface method signature.

πŸ’¬ Discussion


πŸ“Š Question Analytics

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