Why is it recommended to check string length to determine emptiness?
<p>Often, people say that it is better to say <code>s.Length == 0</code> instead of <code>s == ""</code>. But it seems like this would be a microoptimization that also makes it harder to read. Also, ten million of the former as opposed to the latter save at best 60 ms.</p>

<p>Is there a reason that I'm missing, such as if perhaps <code>s.Length == 0</code> actually conveys the intent better? Or is it common to need to compare many strings for emptiness?</p>

<p>EDIT: I know about IsNullOrEmpty, but when people answer the question, they often mention that length checking is better than comparing to the empty string.</p>

<p>EDIT2: Not asking about the best way to do this which would be IsNullOrEmpty for both cases, but I'm asking why it is that a non-negligible minority insist that length checking is superior. I'm assuming that they have some good reasons for saying so, and want to know what they are.</p>

<p>EDIT3: As stated in the beginning, I do know that one is faster than the other. The question is, is that the reason people recommend it? Some timings showed that this did not lead to significant differences.</p>
