A

Admin • 828.43K Points
Coach

Q. Which lambda expression syntax is correct for a function that takes no arguments and returns 5?

  • (A) () -> 5
  • (B) -> 5
  • (C) () => 5
  • (D) (x) -> 5

Explanation by: Admin
`() -> 5` is a correct lambda expression with no parameters returning 5.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.