1

Possible Duplicate:
In C#, should I use string.Empty or String.Empty or “” ?

any difference?

Community
  • 1
  • 1
user496949
  • 83,087
  • 147
  • 309
  • 426

1 Answers1

2

Link

As David implies, there difference between String.Empty and “” are pretty small, but there is a difference. “” actually creates an object, it will likely be pulled out of the string intern pool, but still… while String.Empty creates no object… so if you are really looking for ultimately in memory efficiency, I suggest String.Empty. However, you should keep in mind the difference is so trival you will like never see it in your code…

Note:

...you should keep in mind the difference is so trival you will like never see it...

Glorfindel
  • 21,988
  • 13
  • 81
  • 109
John Hartsock
  • 85,422
  • 23
  • 131
  • 146