Which is the best way to use for String concatenation in
Java?
Answer Posted / leo zhao
Hi Manasa,
You can use append to concatenate more than 2 strings, such as
StringBuffer str = new StringBuffer("Stanford ");
str.append("Lost!!").append(" again.");
| Is This Answer Correct ? | 18 Yes | 2 No |
Post New Answer View All Answers
How does multithreading take place on a computer with a single cpu?
Can a constructor call the constructor of parent class?
What is local variable and instance variable?
How will you initialize an Applet?
What is the use of math abs in java?
Why is inheritance used in java?
Can we have more than one package statement in the source file?
Can a class be private or protected in java?
What is object class in java?
why we use merge option in hybernate pls give a ex snippet
Difference between error and exception
Can main() method in java can return any data?
What is 16 bits called?
What are the different approaches to implement a function to generate a random number?
What is token in java?