&& Operation in .NET

Posted by Ram on Stack Overflow See other posts from Stack Overflow or by Ram
Published on 2010-04-26T10:26:33Z Indexed on 2010/04/26 10:33 UTC
Read the original article Hit count: 102

Filed under:
|
|

Which one out of the following two should be preferred while doing && operation on two values.

 if (!StartTime.Equals(DateTime.MinValue) &&
    !CreationTime.Equals(DateTime.MinValue))

Or

     if (!(StartTime.Equals(DateTime.MinValue) && CreationTime.Equals(DateTime.MinValue))

What is the difference between the two?

© Stack Overflow or respective owner

Related posts about c#

Related posts about .NET