A

Admin • 833.24K Points
Coach

Q. Which keyword is used to return a value from a function in Rust?

  • (A) exit
  • (B) ret
  • (C) return
  • (D) end
  • Correct Answer - Option(C)
  • Views: 29
  • Filed under category Rust
  • Hashtags:

Explanation by: Admin

`return` is used to exit a function and send back a value.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.