Concept Flow - Value types vs reference types mental model
Declare value type variable
Store actual data in variable
Assign value type to another variable
Copy data to new variable
Change new variable value
Original variable unchanged
Declare reference type variable
Store reference (address) to object
Assign reference type to another variable
Copy reference (both point to same object)
Change object via new variable
Original variable sees changed object
Value types hold actual data copied on assignment; reference types hold a pointer to data, so assignments share the same object.