Ill. The Mysterious (?) Art Of Programming; Foreword; What Is A Program; How Do I Program - Sharp PC-1500 Instruction Manual

Hide thumbs Also See for PC-1500:
Table of Contents

Advertisement

All
and more about Sharp
PC-1500
at http://www.PC-1500.info
III.
THE MYSTERIOUS
(?)
ART OF PROGRAMMING
The art of
programming
has heen
needlessly
shrouded in a veil
of
mystery
for
so
long that most
people
associate it with wizardry or
mathematica
l
genius. The
fact
is that no
special
talent for
pulling
rabbits
out
of
hats
is required. Nor is it
necessary
that
you
be
adept at solving partial
differential
equations. Your greatest assets will be your patience,
your logical
rea1oning
abilities,
your
atter>tion
to
detail, and your eagerness to
learn.
A willingness to accept challenges
is
also
useful
(we
won't
kid
you: at
times
programming
is
very challenging. that's
the
fun of
itl
.
Programming is
an art,
and
as
such
requires
a
Ii
ttlc
skill. a
little training, and
a
lot
of practice.
It
is not
our
intent
in
this manual to
make
a seasoned
programmer
out of you. We
\-Viii
familiarize
you with
the
basic operations and concepts
of
programming. To
be
a competent
programmer
requires more,
just
as
good
driving
involves
more than knowing how t<>
steer
and
sh ~ft
gear-s.
Many
good
books on programming
already
exist and
we
strongly urge you
to patronize you
local
computer dealer and
library,
Several
good
books
on
programming
in
general and the BASIC
language
in
particular,
are
listed
in
Appendix
F.
A. What
Is
A
Program?
You
may
br. surprised to discover
that
a
program
is
just
a set of
instructions that
the computer
follows one
at a time. These
instructions
must
b~
given
to the computer
in
a language
it
"under·
stands".
The
SHARP
PC-1500 "speaks" a
dialect
of BASIC, a widely used and
very
popular
programming language.
Like
other
languages, BASIC
has a special
vocabulary
and
grammar
rules
which
are
combined
to
form statements.
It
you
speak to SHA
HP
"ungrammatically", or in
unfamiliar
vocabulary,
the computer
will alert
you
to
your
error.
But it
i~
not
d ifficult
to
correctly
instruct
SHARP.
The
BASIC language
was
originally
developed
to
teach
programming
principles
and
many
of
its
statements
contain English words
and
other
familiar sy1nbols.
B. How Do
I
Program?
As
you
use
SHARP
to
pro~Jram,
you
will
foll<>w a certain
routine.
The
instructions
which make
up
a program are e·ntered
in
the
PROgram mode. These
instructions
are
knovin as
"statements"
in the BASIC
language. To
begin execution ol
th.
e se statements,
it
is
r>ecessary
to
switch to
the
RUN
mode,
and
then to instruct
SHARP to pro.:eed
by
typing the RUN command. For
you
"experts",
who
already have
the two programs of Chapter O under your
bel t.
this will
be
familiar.
For
those
who are pecking
ahead,
let's try entering .and
running
a program:
Switch
to
the
PROgram mode and
issue the
BAS
IC
"command" (more
on
commands
vs.
statements
later
I:
This
will
er•se any
previous statements
which
may
be
left
in
memory. Type
the
following
line:
Program
Listing:
10
PR
INT "GOOD SHOW!
..
Keystrokes:
rn oo
mm
co
Ci.iJ CD
1
'""'1
c:::i
m
CQJ CQJ
CQJ
,
...
c•l
rn
m rn
oo
1
'"'"
1
co
IT-"n
c::::i
,
••
,
••
,
26
Do not
sale
this PDF
!!!

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents