What are alternatives to Strings and string pool and how do they compare?

Java provides several alternatives to Strings and string pooling, such as StringBuilder, StringBuffer, and character arrays. Each of these alternatives has its own advantages and use cases, particularly in terms of mutability, thread safety, and performance.
Alternatives to Strings, StringBuilder, StringBuffer, Character Arrays, Java Strings, Performance in Java

// Example of using StringBuilder in Java
StringBuilder stringBuilder = new StringBuilder();
stringBuilder.append("Hello, ");
stringBuilder.append("World!");
System.out.println(stringBuilder.toString()); // Outputs: Hello, World!
    

Alternatives to Strings StringBuilder StringBuffer Character Arrays Java Strings Performance in Java