<"Felipe Garcia" <#>> wrote:
It's suggested to avoid string concatenations if you are concatenating 5 or
more strings. If you need to concatenate a lot of strings or a number of
strings that you can't predict you should use StringBuilder class. But in
this case i suggest you to take a look at the Concat method of the String
class.
String concatenations such as the one given are fine - if you're
concatenating several strings in one step, it's more effective to do
that than to use a StringBuilder. It's if you end up creating
intermediate strings that things become inefficient.
In the example given, in fact, the compiler does the concatenation in
advance, so it's just a simple string assignment.
--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too