I would like to add that this it is perfectly possible to write purely functional programs that do mutation. You just need to be explicit about it.
Many purely functional data structures also have advanced implementations that need much less copying than "immutable" would at first make you think, since two values can share unchanged structure.
Many purely functional data structures also have advanced implementations that need much less copying than "immutable" would at first make you think, since two values can share unchanged structure.