EasyManua.ls Logo

AMSTRAD CPC464 - Page 61

AMSTRAD CPC464
249 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
1.2.3
Look and see what has happened on the screen:
The computer has been told to display its full character set using the brief program you have just
written. If it hasnt, then youve made an error in typing in the program that you havent noticed -
skip to 1.2.7 and see how to resolve the problem.
Assuming that all is well, and you have the required result, well examine what lies behind the
displayed characters - it will help you understand exactly how your CPC464 communicates through
its range of characters.
The first point is to notice that the computer is not instructed to PRINT abcdefghijklmn...... etc,it is
asked to:
PRINT CHR$(N)
N just happens to be a convenient shorthand note for a variable, the choice of the letter is arbitrary,
it just happens to be the mathematicians favourite in such applications, a variable is an item of
computer information that varies according to the instructions given in the program.
A number like 5 is fixed, it occurs between the numbers 4 and 6 - thus it is not a variable, a
character N is also fixed - its a letter from the alphabet.
So how did the computer know the difference ? If the letter N had been declared to be the
alphabetical character, we would have typed N in quotation marks:
N
- and the computer would have responded with the message Syntax Error because it does not
understand the command sequence FOR N.

Table of Contents

Other manuals for AMSTRAD CPC464

Related product manuals