The Daily Static
  The Daily Static
UF Archives
Register
UF Membership
Ad Free Site
Postcards
Community

Geekfinder
UFie Gear
Advertise on UF

Forum Rules
& FAQ


Username

Password


Create a New Account

 
 

Back to UserFriendly Strip Comments Index

Logic operator associativity question by thetree2009-12-02 09:26:24
  ITYM "precedence" by pas512009-12-02 09:42:21
    I think they changed that in C++. by Lethosos2009-12-02 09:44:03
      Nope. by pas51 2009-12-02 10:02:21
click

Nor is it moot, since the answer to thetree's question is that the AND is evaluated first, not because it happens to be the left-most operator, but because it takes precedence over OR (and would therefore be evaluated first even if it were the right-most operator).

Given the scope for confusion, I suspect that predicate logicians do not write "A && B || C" but rather "(A && B) || C" or "A && (B || C)".

[ Reply ]
        No; thetree is looking for by MatthewDBA2009-12-02 10:08:56
          Not necessarily. by pas512009-12-02 10:45:08
            Hmm, interesting. by MatthewDBA2009-12-02 11:45:33

 

[Todays Cartoon Discussion] [News Index]

Come get yer ARS (Account Registration System) Source Code here!
All images, characters, content and text are copyrighted and trademarks of J.D. Frazer except where other ownership applies. Don't do bad things, we have lawyers.
UserFriendly.Org and its operators are not liable for comments or content posted by its visitors, and will cheerfully assist the lawful authorities in hunting down script-kiddies, spammers and other net scum. And if you're really bad, we'll call your mom. (We're not kidding, we've done it before.)