Correctly Checking for Null in C#

Опубликовано: 21 Апрель 2026
на канале: DevChatter
2,659
71

You may have heard that is null is better than == null, but do you know why?
Starting with C# 7 the pattern matching in C# let you compare to the constant value null instead of doing an equality comparison.

Sample Code Used in the Video: https://github.com/DevChatter/YouTube...

Watch our live stream at   / devchatter  

Chat with us on Discord -   / discord  

Contribute on GitHub - https://github.com/DevChatter/

Support DevChatter through Patreon -   / devchatter  

Follow Brendan on Twitter -   / brendoneus  

Brendan's Pluralsight Courses - https://www.pluralsight.com/authors/b...

#shorts
#programming
#csharp
#Coding
#dotnet
#Tutorial