EasyManuals Logo

Atari 400 User Manual

Atari 400
326 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #59 background imageLoading...
Page #59 background image
Introduction
to Atari BASIC
57
decided
not
to
purchase
the
items that Steve
wanted,
she
would
be acting
under
the
NOT
logical
operation.
The
NOT,
AND,
and
OR logical operators are summarized in
Illustration
3-3.
A
logical
operator
evaluates
an
input
of
one
or
more
operands
with
true
or
false values. The logical
operator
evaluates these
true
or
false values and returns a value
of
true
or
false itself.
An
operand
of
a logical
operator
is
evaluated
as
true
if it
has
a
non-
zero value.
(Remember
, relational
operators
return
a value
of
1
for
a
true
value.). An
operand
of
a logical
operator
is
evaluated
as
false
if it
is
equal
to
zero
.
The
result
of
a logical
operation
is
also a
number
,
which
if
non-
zero
is
considered
true,
and false
if
it
is
zero.
The
following
are examples
of
the
use
of
logical
operators
in
combination
with
relational operators in
decision
making.
IF
X >
10
OR
Y < 0 THEN
900
IF
A > 0
AND
B > 0 THEN
200
ELSE
GOTO
300
B =
-l:PRINT
NOT
B
In
the
first
example
,
the
result
of
the
logical
operation
will
be
true
if
variable X
has
a value greater than
10
or
if
variable Y
has
a
value
less
than
o.
Otherwise,
it
will
be
false. If
the
result
of
the
logical
operation
is
true
,
the
program
will
branch
to
line
900.
Otherwise
,
it
will
continue
to
the
next
statement.
In
the
second
example
,
the
result
of
the
logical
operation
will
be
true
only
if
the
value
of
both
variables A
and
B are
greater
than
zero
.
If
the
result
of
the
logical
operation
is
true
,
program
control
will
branch
to
line
200
.
Otherwise
,
program
control
will
branch
to
line
300.
In
the
third
example,
B
is
set
to
a value
of
-1 (true). The value
of
NOT
B
is
then
printed.
This
will
be 0
or
false.
Illustration
3-3 contains tables that may
prove
of
help
when
evaluating
program
statements using logical
operators
in
combination
with
relational operators.

Other manuals for Atari 400

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Atari 400 and is the answer not in the manual?

Atari 400 Specifications

General IconGeneral
ManufacturerAtari
Model400
TypeHome Computer
Release Year1979
CPUMOS Technology 6502
CPU Speed1.79 MHz
ROM10 KB
Operating SystemAtari OS
KeyboardMembrane keyboard
RAM8 KB (expandable to 48 KB)
GraphicsANTIC and GTIA chips
Sound4 channels
DisplayRF output for connection to TV
StorageOptional cassette tape drive or floppy disk drive
PortsCartridge
Display Resolution320x192 (16 colors)

Related product manuals