The Dink Network

Reply to Re: if (&crap == 1 && &morecrap == 1) ???

If you don't have an account, just leave the password field blank.
Username:
Password:
Subject:
Antispam: Enter Dink Smallwood's last name (surname) below.
Formatting: :) :( ;( :P ;) :D >( : :s :O evil cat blood
Bold font Italic font hyperlink Code tags
Message:
 
 
August 4th 2002, 09:10 AM
wizardg.gif
Paul
Peasant He/Him United States
 
: hmmm...it'd be interesting to know HOW closely based on C dinkC is... the || operator could be really usefull too...

: when you find out, tell us, ok??

: thanks.

Instead of just making to if statments with whatever code I need run in either case, I sometimes do this to simulate an OR.

int &value = 0;

if (&crap == 1)

&value = 1;

if (&morecrap == 1)

&value = 1;

if (&value == 1)

{

//do stuff

}

This is particularly worth doing if "do stuff" is many lines long.