Differences between String class and String Buffer class?

Differences between string class and string buffer class:

String objects are immutable and string buffer objects are mutable.

Methods to manipulate the data are not available in string class. they are available in string buffer class

Mutable: mutable objects are these objects whose content can be modified.

Ex: String Bufferclass


Immutable: immutable objects are those objects whose content can’t be modified.

Ex: String class.

Related

Java 8056923249139658611

Post a Comment

emo-but-icon

item