Friday, February 04, 2011

?? Operator


?? operator is null-coalescing operator. It is used with nullable value types and reference types. It returns left hand operand if it is not null. If left hand is null and right hand is not null, it returns right hand operand. In case both the operands are null, it returns null. We can say that it just check for left hand side operand and returns anyway if left is null.


No comments:

Post a Comment