After; And - AMSTRAD cpc 6128 User Instruction

Integrated computer/disc system
Hide thumbs Also See for cpc 6128:
Table of Contents

Advertisement

AFTER
AFT E R <timer delay>[, <timer number>] GO SUB <line number>
10 AFTER 250 GOSUB 60:CLS
20 PRINT "Guess a Letter in 5 seconds"
30 a$=INKEY$:IF fLag=1 THEN END
40 IF a$<>CHR$(INT(RND*26+97»
THEN 30
50 PRINT a$;" is correct. You win"
55 SOUND 1,478:S0UND 1,358:END
60 PRINT "too Late. I win"
70 SOUND 1,2000:fLag=1:RETURN
run
COMMAND: Calls a BASIC sub-routine after a given period of time has elapsed. The
<timer delay> parameter specifies the period of time in units of 0.02 (fiftieths) second.
The <timer number> (in the range 0 to 3) specifies which of the four delay timers are to
be used. Timer 3 has the highest priority; timer 0 (the default timer) has the lowest.
Each ofthe timers may have a sub-routine associated with it
Further information concerning interrupts will be found in part 2 of the chapter
entitled 'At your leisure .... >.
Associatedkeywords: EVERY, REMAIN, RETURN
AND
<argument> AND <argument>
IF "aLan"<"bob" AND "dog">"cat" THEN PRINT "correct" ELSE PRINT "wrong"
correct
I F "bob"<"aLan"
wrong
IF "aLan"<"bob"
wrong
PRINT1AND1
1
PRINT0AND0
o
PRINT1AND0
o
AND "cat">"dog" THEN
AND "cat">"dog" THEN
PRINT "correct" ELSE PRINT "wrong"
PRINT "correct" ELSE PRINT "wrong"
OPERATOR: Performs bit-wise boolean operation on integers. Result is
0
unless
both argument bits are 1 .
Further information concerning logic will be found in part 2 of the chapter entitled
'At your leisure .... '.
Associated keywords: 0 R, NOT, X 0 R
Chapter 3 Page 4
Complete List of Keywords

Advertisement

Table of Contents
loading

Table of Contents