Immutability
Immutability refers to the property of an object or data structure that prevents it from being changed after it has been created. In programming, this means that once an immutable object is created, its state cannot be modified. This can help avoid unintended side effects and make code easier to understand and maintain.
In many programming languages, such as Java and Python, certain data types are immutable. For example, strings in Python cannot be altered; any modification results in the creation of a new string. Immutability is often used in functional programming to promote safer and more predictable code.