"Instead use IEnumerable< T >.Lacks(T item)"
"Instead use IEnumerable< T >.Lacks(T item, bool caseSensitive)"
Human brain can understand positive expressions and statements faster than negative ones. To improve code readability it is better to use Lacks
rather than !Contains
.
if (!myStringList.Contains(myVar))
{
...
}
should be 🡻
if (myStringList.Lacks(myVar))
{
...
}