Herunterladen Inhalt Inhalt Diese Seite drucken
Inhaltsverzeichnis
DATA <Konstantenliste>
S p e i c h e r t numerische und S t r i n g - K o n s t a n t e n ,
auf d i e m i t der READ-Anweisung
3.3.25) z u g e g r i f f e n werden kann.
DATA-Anweisungen s i n d n i c h t a u s f u e h r b a r e An-
weisungen, d i e an b e l i e b i g e r S t e l l e
gramm
s t e h e n
kann s o v i e l e Konstanten e n t h a l t e n , w i e , ge-
t r e n n t durch Komma, i n e i n e B e f e h l s z e i l e (88
Z e i c h e n ) p a s s e n . Die Zahl der DATA-Anweisun-
gen
i s t b e l i e b i g . Die READ-Anweisung
d i e e i n z e l n e n DATA-Zeilen i n der R e i h e n f o l g e
von deren Zeilennummern. Die i n d i e s e n
l e n e n t h a l t e n e n Daten werden unabhaengig von
i h r e r
Zahl und deren P l a z i e r u n g im Programm
a l s k o n t i n u i e r l i c h e E l e m e n t l i s t e a u f g e f a s s t .
<Konstantenliste>kann numerische K o n s t a n t e n
jeden F o r m a t s , d.h. Gleitkomma-
Zahlen e n t h a l t e n . Numerische Ausdruecke s i n d
n i c h t e r l a u b t . S t r i n g - K o n s t a n t e n i n DATA-An-
weisungen muessen
s t r i c h e
(") e i n g e k l e i d e t
Kommas,
Doppelpunkte
n a c h l a u f e n d e
s i g n i f i k a n t e
h a l t e n .
Der
i n d e r READ-Anweisung d e k l a r i e r t e Va-
r i a b l e n t y p
(numerisch oder S t r i n g ) muss m i t
dem
i n den
zugehoerigen
e n t h a l t e n e n Konstantentyp u e b e r e i n s t i m m e n .
Der
L e s e z e i g e r
sung ( s . Abschn. 3.3.27) auf den Anfang der
e r s t e n DATA-Anweisung g e s t e l l t werden.
10

DATA

"DAS
"."SCHOEN !"
20 FOR 1=1 TO 5
30 READ A$
40 PRINT A$;
50 NEXT
RUN
DAS WETTER I S T HEUTE SCHOEN !
READY.
54
koennen.
Jede
nur dann
i n Anfuehrungs-
werden,
oder
L e e r s t e l l e n
DATA-Anweisungen
kann mit der RESTORE-Anwei¬
"."WETTER
" , " I S T
( s . Abschn.
im Pro-
DATA-Anweisung
l i e s t
Z e i -
oder
ganze
wenn s i e
v o r -
und/oder
e n t -
"."HEUTE
Inhaltsverzeichnis
loading

Verwandte Produkte für Commodore Computer VolksComputer VC-20

Inhaltsverzeichnis