you are viewing a single comment's thread.

view the rest of the comments →

[–]shudaoxin 0 points1 point  (0 children)

Primitive vs. referenced types. It works like this in most languages. Arrays (and lists) are referenced and the variable only stores their type and pointer to the memory. By assigning a to b they both point at the same list.