Everything2
Near Matches
Ignore Exact
Full Text
Everything2

Boolean logic

created by zanda

(thing) by zanda (4.9 y) (print)   ?   I like it! Wed Jul 24 2002 at 16:24:25

Boolean logic is a system of using logic in computing,
invented by George Boole in the mid 1800's.

0 = False
1 = True
(1 and 0 is just how we see it, but a computer sees it as
off and on)

AND (both values have to be true)
1 AND 1 = 1
1 AND 0 = 0
0 AND 1 = 0
0 AND 0 = 0

OR (One of both of the values has to be true)
1 OR 1 = 1
1 OR 0 = 1
0 OR 1 = 1
0 OR 0 = 0

NOT (invert)
NOT 1 = 0
NOT 0 = 1

XOR (eXclusive OR, only one value can be true)
1 XOR 1 = 0
1 XOR 0 = 1
0 XOR 1 = 1
0 XOR 0 = 0

NAND, NOR, XNOR?
By putting NOT in front of another gate you can invert the result of the original operation

E.G. NAND (NOTAND)
1 NAND 1 = 0
1 NAND 0 = 1
0 NAND 1 = 1
0 NAND 0 = 1

Boolean logic can be used in a number of ways..
The IF statement
If ( var = 1 ) ...
This is basically saying do this if the statement is true
do this. But how would you do an if where two things
must be true?
if ( (var = 1) AND (foo = 2) ) ...
XOR can even be used to swap to variables without using a
third.

printable version
chaos

Euler's Method Boolean algebra George Boole XOR
Logic gate Boolean law semantic proof NAND
hacker The New Turing Omnibus How to exchange two variables without using a third and
Artificial Intelligence Speedtalk Infinite Improbability Drive ASCII
not or Beyond Belief: Christian Arguments for God's Existence The Christian God and Particle Physics
Bizarre anti-Semitic interview with Bobby Fischer Excluded Middle Ultima VII boolean
Y'know, if you log in, you can write something here, or contact authors directly on the site. Create a New User if you don't already have an account.
  Epicenter
Login
Password

password reminder
register

Everything2 Help

Cool Staff Picks
After stirring Everything, these nodes rose to the top:
How to hide
transcendental number
JFK Junior Ate My Television
Robert Crumb
cavitation torpedo
July 30, 2003
Michael was special
lavarand
jazz
Pennsylvania Turnpike
Skin hunger
Mattbox: Mac OS X Chatterbox Client
Orson Welles
New Writeups
everyday j.Lo
pray do not molest them(thing)
ammie
Bands Who Take Their Names from Eighteenth-century English Poetry and Prose(idea)
shaogo
Under My Thumb(review)
ammie
Rock On(person)
The Custodian
The Dresden Files(thing)
Ouzo
PETA becomes you, a proposed future(fiction)
Ereneta
Stone Soup, Part Two(fiction)
jjen
Sorrier than I ever thought I would be(personal)
locke baron
Moskva class antisubmarine cruiser(thing)
Wuukiee
May 15, 2008(idea)
locke baron
Kuznetsov class aircraft carrier(thing)
Adaptive Child
Annie's garden salsa(recipe)
Simulacron3
Zig-Zag(thing)
Noung
Tiananmen Square Massacre(idea)
aneurin
Lord St Clair(person)
This affordable entertainment brought to you by The Everything Development Company