[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
Function: And()
---------
FORCE Prototypes:
-----------------
FUNCTION UINT and PROTOTYPE
PARAMETERS VALUE UINT word1, VALUE UINT word2
Description:
------------
These functions implement three bitwise operations,
Logical AND, OR, and XOR. They each take two integer values,
and perform their logical function upon the two. The result
of that operation is returned.
For those of you not familiar with the logical operands, here's
a table, in binary, so that you can see how they work.
01001010 01001010 01001010
AND 00001010 OR 00101010 XOR 00101010
-------- -------- --------
00001010 01101010 01100000
If you can't figure it out, here it is in english:
AND will test two bits at a time, one from each word. The
resulting bit will be 1 if the first bit AND the second bit
are both 1.
*- Examples:
? and( 1, 3 ) && prints 1, because 1 and 3 look like:
&& 00000001 AND 00000011 ->
See Also:
Or()
Xor()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson