Operators
slayer@kaiwan.com (slayer@kaiwan.com)
Thu, 11 Apr 1996 21:47:22 PDT
At 09:26 PM 4/11/96 PDT, Jefferson M. Dubrule wrote:
>--- "Matthew `GrendelFish' Dockrey" wrote:
>And ((x && !y) || (!x && y)) is fairly clunky.
>--- end of quoted material ---
>Sorry to reply twice, but here's a slightly more elegant, slightly less obvious
>way:
>((!!x + !!y) == 1)
>
>-manta
>
yeah, but that way takes as much as 3 extra ticks (varies depending on the
values for x and y), but should only be important if you're doing a long
loop (such as evaluating for p in (players()).
>
>