The Rust SuperpowerOwnership 101: Move, Don't Copy
All courses

One owner at a time

Each value has exactly one owner. Assigning a String moves it — the old binding is invalid. No double-free, no use-after-free. The compiler enforces this at compile time.

Quirk: Integers implement Copy — they duplicate instead of move. String does not. This distinction will become your personality.

Output
Press Run to execute your code.