Think In Geek

In geek we trust

October 12th, 2009

C#, the “and” operators and lazy evaluation

Today at work we found a bug. My workmate, not used to C#, usually uses the & operator to compare boolean values. However, in C#, the & operator does not use lazy evaluation. One curious thing about C# is that it can use two different operators to calculate an and expression: the & operator and […]

,