Difference between revisions of "Bit.band"
From ComputerCraft Wiki
(Created page with " == Explanation == <i>AND</i> is a gate that is only on when both inputs are on. (ex. (0,0)=0; (1,0)=0; (0,1)=0; (1,1)=1) == Other than Binary == <i>AND</i> can be used as a ...") |
Scarfacial (Talk | contribs) (You don't need to sign articles.) |
||
Line 1: | Line 1: | ||
− | + | {{stub}} | |
== Explanation == | == Explanation == | ||
− | + | ''AND'' is a gate that is only on when both inputs are on. (ex. (0,0)=0; (1,0)=0; (0,1)=0; (1,1)=1) | |
== Other than Binary == | == Other than Binary == | ||
− | + | ''AND'' can be used as a basic ''if equals' command, but isn't very reliable due to its behavior. When the lowest number is even and you count up it will pulse that number for as many times as that number. (ex. if 2 is the lowest number: 2=2 3=2, 4=0, 5=0, 6=2, 7=2, 8=0, 9=0, 10=2, 11=2, 12=0) However, if the lowest number is odd it will count up to that number then return to zero and start again. (ex. if you use 3 you get: 4=0, 5=1, 6=2, 7=3, 8=0, 9=1, 10=2, 11=3, 12=0) | |
− | + | ||
− | + |
Revision as of 01:40, 27 February 2012
This page is a stub. Please help us by expanding it.
|
Explanation
AND is a gate that is only on when both inputs are on. (ex. (0,0)=0; (1,0)=0; (0,1)=0; (1,1)=1)
Other than Binary
AND can be used as a basic if equals' command, but isn't very reliable due to its behavior. When the lowest number is even and you count up it will pulse that number for as many times as that number. (ex. if 2 is the lowest number: 2=2 3=2, 4=0, 5=0, 6=2, 7=2, 8=0, 9=0, 10=2, 11=2, 12=0) However, if the lowest number is odd it will count up to that number then return to zero and start again. (ex. if you use 3 you get: 4=0, 5=1, 6=2, 7=3, 8=0, 9=1, 10=2, 11=3, 12=0)