Re:What If I Don't Actually Like My Users? (2008)
by lfowles on Friday June 03, 2016 @12:34PM
(#11831329)
>> ((strcmp(a, b) == 0) != false)
>I have never seen that. And would never advocate for that, why are we doing it that way again?
I think a more reasonable example would be (with some reasonably namespaced define, blah blah blah):
strcmp(a, b) == CMP_EQUAL;
> "not" means "no difference
I'd rather see less "not"s, it is easier to reason about. "not" means logical expressions to me, strcmp returns numbers, I would rather keep ! away.
> "if(!p)" means "there is no (object pointed to by) p".
Ok, now we have pointer in play. strcmp really does return numbers. Why bring pointers or logic operators, doesn't that confuse things? It does for me.
> ((strcmp(a, b) == 0) != false)
I have never seen that. And would never advocate for that, why are we doing it that way again?