Java
StringBuilder and StringBuffer in Java
When text is built piece by piece, a mutable buffer avoids the copying that repeated String concatenation forces.
String handling in Java.
2 notes tagged
When text is built piece by piece, a mutable buffer avoids the copying that repeated String concatenation forces.
String is an immutable object with a shared literal pool, and both facts explain how comparison, concatenation and performance behave.