Top "Mutable" questions

A mutable can be modified after it is created.

Using volatile keyword with mutable object

In Java, I understand that volatile keyword provides visibility to variables. The question is, if a variable is a reference …

java concurrency volatile mutable
Good uses for mutable function argument default values?

It is a common mistake in Python to set a mutable object as the default value of an argument in …

python arguments default-value mutable
Converting immutable to mutable collections

What is the best way to convert collection.immutable.Set to collection.mutable.Set?

scala collections immutability mutable
How do I pass a reference to mutable data in Rust?

I want to create a mutable struct on the stack and mutate it from helper functions. #[derive(Debug)] struct Game { …

pointers mutable rust
What's the difference between placing "mut" before a variable name and after the ":"?

Here are two function signatures I saw in the Rust documentation: fn modify_foo(mut foo: Box<i32>) { *…

variables syntax reference rust mutable
Why is there no mutable TreeMap in Scala?

Is it lack of time, some technical problem or is there a reason why it should not exist?

scala collections map tree mutable
How do I pass a mutable vector as a function parameter in Rust?

I am implementing a small program that evaluates the Collatz conjecture. As part of this, I have a function that …

rust mutable
static mutable member variables in C++?

why or for what reason is it not possible to declare a class member variable in C++ as static mutable? …

c++ static member mutable
How to convert immutable Seq to mutable seq with until loop

I'm trying to return a mutable Sequence with an until loop, but i have an immutable seq in return of (0 …

scala sequence immutability mutable
Python: Replacing an element in a list of lists (#2)

A previous question with the same title as mine has been posted, with (I think) the same question, but had …

python list mutable