Beginner Rust
Q24 / 100

What is Cell<T> and RefCell<T>?

Correct! Well done.

Incorrect.

The correct answer is B) Types providing interior mutability: Cell<T> for Copy types, RefCell<T> for runtime-checked borrows

B

Correct Answer

Types providing interior mutability: Cell<T> for Copy types, RefCell<T> for runtime-checked borrows

Explanation

Interior mutability allows mutation through an immutable reference. RefCell<T> enforces borrow rules at runtime, panicking on violations.

Progress
24/100