📜  java string vs stringbuilder - Java 代码示例

📅  最后修改于: 2022-03-11 14:52:16.848000             🧑  作者: Mango

代码示例1
A String can be used when immutability is required, or concatenation operation is not required. A StringBuilder can be used when a mutable string is needed without the performance overhead of constructing lots of strings along the way.