concept place in category kotlin

This is an excerpt from Manning's book The Joy of Kotlin.
5.3.2 Avoiding in-place mutation
Most data structures change over time because elements are inserted and removed. To handle such operations, you can use two approaches. The first one is update in place.
Update in place consists of changing the elements of the data structure by mutating the structure itself. This was considered a good idea when all programs were single-threaded (although it wasn’t). It’s even much worse now that all programs are multithreaded. This doesn’t only concern replacing elements. It’s the same for adding or removing, sorting, and all operations that mutate the structure. If programs are allowed to mutate data structures, these structures can’t be shared without sophisticated protections that are rarely done right the first time, leading to deadlock, livelock, thread starving, stale data, and all sorts of troubles.
Update in place