I want to compare 4 strings if they are equal or not. The problem is that I have to ignore the empty strings, but if they are all empty then the method must also return true, because all empty strings are equal. I could write everything down like
if(string1 != string.Empty && string2 != string.Empty &&
string1 != string2)
{
return false
}
if(string1 != string.Empty && string2 != string.Empty && string3 != etc....
But I think there is a better way then writing out all the possibilities. But how?