www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/10/18/14:19:16

Message-ID: <3BCF1AC4.B82C3FE1@earthlink.net>
From: Martin Ambuhl <mambuhl AT earthlink DOT net>
Organization: Nocturnal Aviation
X-Mailer: Mozilla 4.77 [en] (Win95; U)
X-Accept-Language: en,de-CH,fr,ru,zh-CN,ja
MIME-Version: 1.0
Newsgroups: comp.lang.c++,comp.os.msdos.djgpp
Subject: Re: Making C++ little easier to beginners...
References: <9qmkrh$581$1 AT tron DOT sci DOT fi>
Lines: 24
Date: Thu, 18 Oct 2001 18:06:22 GMT
NNTP-Posting-Host: 165.247.41.251
X-Complaints-To: abuse AT earthlink DOT net
X-Trace: newsread2.prod.itd.earthlink.net 1003428382 165.247.41.251 (Thu, 18 Oct 2001 11:06:22 PDT)
NNTP-Posting-Date: Thu, 18 Oct 2001 11:06:22 PDT
X-Received-Date: Thu, 18 Oct 2001 11:02:31 PDT (newsmaster1.prod.itd.earthlink.net)
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Traveler wrote:
> Little example...
> int    x = 10,
>         y = 10;
> if(x == 10 && x == 10)        // Does this look scary or weird to you> 

Only because you are making the same comparison twice.
[...]

> if(x EQUAL 10 AND y EQUAL 10)

No.  If you want COBOL, then use COBOL.

[...]
> #define    AND        &
> #define    COMPLEMENT    ~
> #define    EQUAL    ==
> #define    EQU        EQUAL
> #define    NOT        !
> #define    OR            |
> #define    XOR        ^

This sort of stupidity raises its head every year, usually in September.
But, as we know, September never ends.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019