hi to all. well can you please tell me that why String class
is immutable?

Thanks in advance.

Answer Posted / syed

Since, return type of the string class cannot be altered
with substrings or any ammendments to it .

Is This Answer Correct ?    0 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is data structure in java?

510


Explain about the performance aspects of core java?

530


what is thread? What are the high-level thread states? Or what are the states associated in the thread? : Java thread

470


what is the purpose of the wait(), notify(), and notifyall() methods? : Java thread

534


What is the difference between a method and a procedure?

520






How do you initialize an arraylist in java?

476


Why set do not allow duplicates in java?

553


Do loops java?

525


Can a main method be overloaded?

547


What does int argc char * argv [] mean?

487


What is the benefit of inner classes in java?

574


Does java set allow duplicates?

496


Explain an algorithm to find depth of a binary tree.

515


What is byte code and why is it important to java’s use for internet programming?

576


What do bitwise operators do?

503