Qus:    Why are the objects immutable in java?
Oct 23, 2021 03:59 1 Answers Views: 31 VAMSI
Prev Next
Answers (1)
ROHAN Nov 03, 2021 04:32
Answer:   Because Java uses the concept of the string literal. Suppose there are five reference variables, all refer to one object "sachin". If one reference variable changes the value of the object, it will be affected by all the reference variables.

Post Your Answer
Guest User

Not sure what course is right for you?

Choose the right course for you.
Get the help of our experts and find a course that best suits your needs.


Let`s Connect