Radio Shack TRS-80 User Manual page 149

Micro computer system
Hide thumbs Also See for TRS-80:
Table of Contents

Advertisement

Chapter 24
AND & OR
In
classical
mathematics
(fancy
words
for
simple
ideas)
there
exist
what
are
known
as
the
"logical
AND"
and
the
"logical
OR".
So
the
One
Cow
Said to the
Other
Cow
.
.
.
In
Figure
1,
if
Gate
A
AND
gate
B
AND
gate
C
are
open, the
cow
can
move
from
Pasture
#
1
to
Pasture
#2.
If
any
gate
is
closed,
the cow's path
is
blocked.
PASTURE
#1
ft
,
cow
,/
GATE
A
/
GATEB
PASTURE
#2
/
GATE
C
FIGURE
1
The
principle
is
called "logical
AND".
In
Figure
2,
if
gate
X
OR
gate
Y
OR
gate
Z
are
open, then
old Bess can
move
from
Pasture
#3
to
#4. That
principle
is
called "logical
OR".
These
ideas are
both
pretty
logical. If
the
cow
can
figure
them
out
surely
you
can!
PASTURE
#3
f^f
OLD
BESS
PASTURE
#4
/gate
X
t
c/gate Y
1
gatez
FIGURE
2
Grit
Your
Teeth and
Prepare
to
Say
AAAAAGHH!!
Somewhere
in
the misty
history
of
classical
mathematics,
a
budding
genius
dedicated the
symbol
"X"
to
mean
AND,
and
"+"
to
mean OR.
Ordinary
arithmetic of course uses
"X"
to
mean
multiply
and
"+"
to
mean
add.
To
further
confuse
the matter, instead of
"X",
for
computers
we
use
"*"
to
mean
multiply.
Our
logical
AND
symbol,
therefore,
is
"*".
AAAAAAGH!!!!!
(I
told
you.)
By
the
way,
this
cow's
name
is
Bessie.
K^
I
\ "*
?^%^
~;~^™;-~;
TCSSin-IT'S
ONLY
LOGICAL.'
-"./'."''-.
;."'
--
:.^-
:
^."
:
::i""-'-
|
.l
Now
don't forget..
.
in
"logical"
computer work:
*
means
AND
+ means
OR
147

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents