20. Compare the features of immutable and mutable objects of a session
Answers
Answered by
3
Answer:
A mutable object can be changed after it's created, and an immutable object can't. That said, if you're defining your own class, you can make its objects immutable by making all fields final and private. Strings can be mutable or immutable depending on the language.
Similar questions
Science,
6 months ago
Environmental Sciences,
1 year ago
Social Sciences,
1 year ago
Social Sciences,
1 year ago