EasyManua.ls Logo

AMSTRAD CPC464 - Page 138

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...
CREAL
CREAL(<numeric expression>)
5 DEFINT n
10 n=75.765
20 d=n/34.6
30 PRINT d
40 PRINT CREAL(n)
50 PRINT n/55.4
run
2.19653179
76
1.37184116
Ready
FUNCTION: Converts a value to a real number. (As opposed to integer).
Associated keywords: CINT
DATA
DATA <list of constant)
10 REM Proofreader
20 DIM Proofer$(5)
30 DIM ProoferSurname$(5)
40 FOR n=l to 5
50 READ Proofer$(n)
60 READ ProoferSurname$(n)
65 PRINT Proofer$(n);" "ProoferSurname$(n)
70 DATA Bob,Smith,Dicky,Jones,
Malcolm,Green,Alan,Brown,Ivor,Curry
90 NEXT
COMMAND: Declares constant data for use within a program. One of the most widely used features
of BASIC that lumps constant data in DATA statements for retrieval as required. The data type
must be consistent with the variable invoking it. A DATA statement may appear anywhere in a
program.
Associated keywords: READ, RESTORE

Table of Contents

Other manuals for AMSTRAD CPC464

Related product manuals