Through the medium of the program, the computer breaks down every task into a simple series of
Yes/No operations.
The process of multiplication is performed using multiple additions - the BASIC instruction to
multiply 35 by 10 (35*10) gets to the answer by adding 35 to itself ten times.
Part of the
Central Processor Unit (CPU)
is loaded with the numeric data for 10, and another part of
the CPU is loaded with 35. Each time 35 is added to itself, the part of memory containing 10 is
decreased by one until it reaches zero, when the process stops, and the accumulated result of 350 is
sent
to
another
part
of
the
CPU
for
Output
as
the
answer.
If this process sounds cumbersome, then you’re quite right, as you have uncovered the first and most
important truth about computing. A computer is primarily a tool for performing the simplest of
repetitive tasks very quickly and with absolute precision, Thus BASIC interprets the instructions
given in the form of the program, and translates them into the language that can be handled by the
CPU. Only two states are understood by the logic of a computer - ‘yes’ or ‘no’, represented in binary
notation as ‘1’ and ‘0’. The representation in Boolean logic is simply ‘true’ and ‘false’ - there’s no such
thing as a ‘maybe’ or ‘perhaps’.
The process of switching between these two distinct states is the essence of the term digital, and ‘is
sometimes referred to as toggling. In the world of nature, most processes move gradually from one
completely ‘stable’ state to another in a smooth progression. In other words, the transition is made
by following the path of a line between the two states - in an ideal digital environment the switch
from one state to the next is made in no time at all - but the physics of semiconductor science dictate
that there will be some minor delay, referred to as propagation delays - and it is the accumulation of
many of these propagation delays that provides the reason why a computer has to spend some time
processing the information before the answer comes out.
In any case, the computer would have to wait a finite time for one task to have finished before it can
start work on the result of that first task - so there would need to be some artificial delay imposed
anyway. The digital process is black or white where the stages in the transition via shades of grey
have no significance whatsoever. The smooth progression is via various shades of grey.
Содержание CPC464
Страница 1: ......
Страница 32: ...or you can type 3e1 1e1 ENTER 300 2 3000x1000 Type 3e3 1e3 ENTER 3000000 3 3000x0 001 Type 3e3 1e 3 ENTER 3 ...
Страница 102: ...PRINT 10 AND 12 Results in 8 PRINT 10 AND 1000 Results in 8 again ...
Страница 118: ...TO DO DRAW THIS PAGE ...
Страница 219: ...actual value may be made to vary during the execution of a program ...
Страница 240: ...Text and WINDOW planner Mode 2 80 Columns ...
Страница 241: ......
Страница 245: ...Sound envelope Music planner sheet ...