I\'m trying to understand what the best practice is and why for concatenating string literals and variables for different cases. For instance, if I have code like this
I personally prefer the Strings.format(), simple easy to read one-line string formatter.
Strings.format()
String b = "B value"; String d = "D value"; String fullString = String.format("A %s C %s E F", b, d); // Output: A B value C D value E F