Author Topic: What is the "or" in c# or torque whatever =;=  (Read 1043 times)

like ik "&&" but idk "or" in code lol please help and reply fast ;=;

It is & or &&. - That is for and in the statements

There is also else if. Example:

function chocolate()
{
   $chocolate++; //Adds 1 more of this value
   if($chocolate == 1)
      //stiff
   else if($chocolate == 2 || $chocolate == 4)
      //stiff
   else
      //other stuff
}


Also
||
Updating code.
« Last Edit: October 15, 2013, 08:57:32 PM by Advanced Bot »


It is & or &&. - That is for and in the statements

There is also else if. Example:

function chocolate()
{
   $chocolate++; //Adds 1 more of this value
   if($chocolate == 1)
      //stiff
   else if($chocolate == 2 || $chocolate == 4)
      //stiff
   else
      //other stuff
}


AlsoUpdating code.

Actually i needed this too after all! lol ty
« Last Edit: October 15, 2013, 09:23:12 PM by chubaka452 »

is there a limit to the "||"

is there a limit to the "||"
what do you mean
if(%value == 2 || %string $= "fart")

I suggest looking at the scripts inside some add-ons posted on the forum, or for more general and encompassing coding guides available.


is there a limit to the "||"

the limit of writing "a || b || c || d || ..." varies based on the size of whatever you're storing the .cs file on

the limit of writing "a || b || c || d || ..." varies based on the size of whatever you're storing the .cs file on
and how deranged and sadistic you are