A

Admin • 833.24K Points
Coach

Q. What does the `drop` function do in Rust?

  • (A) Deletes the variable
  • (B) Forces the value to be dropped (deallocated) immediately
  • (C) Increments the reference count
  • (D) Freezes the variable
  • Correct Answer - Option(B)
  • Views: 29
  • Filed under category Rust
  • Hashtags:

Explanation by: Admin

`drop()` manually drops (deallocates) a value early.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.