"Negative logical comparisons are taxing on the brain. Instead of "!object.Any()" use "object.None()"."
Comparisons are more clear and meaningful while we don’t use negative syntax.
if(!myObj.HasValue)
{
...
}should be 🡻
if(myObj == null)
{
...
}if(!data.Any(d => d.ProductCode == 120))
{
...
} should be 🡻
if(data.None(d => d.ProductCode == 120))
{
...
}