Trace

Authors

Publication

Pub Details

Date

Pages

BASIC Terms

Key in this short listing to trace the variables in your program. Place it in front of your program and GO TO 5 to use it. You will get a list of the lines that the variable you are looking for is in.

BASIC Listing

   5 INPUT "Variable to view ",v$: LET l=LEN v$
10 LET p=PEEK 23635+256*PEEK 23636
15 LET v=PEEK 23627+256*PEEK 23628
20 LET n=256*PEEK p+PEEK (p+1)
25 LET le=PEEK (p+2)+256*PEEK (p+3)
30 PRINT n
35 LET q=0: LET c=1: FOR j=4 TO le+4
40 LET p1=PEEK (p+j)
45 IF p1=34 THEN LET q=NOT q
50 IF q THEN GO TO 90
55 IF p1=14 THEN LET j=j+5: GO TO 90
60 IF p1=58 THEN LET c=c+1
65 IF p1<>CODE v$(1) THEN GO TO 90
70 FOR k=1 TO l
75 LET p1=PEEK (p+j+k-1): IF p1<>CODE v$(k) THEN GO TO 90
80 NEXT k: LET k=PEEK (p+j+k-1): IF k=36 OR (k>47 AND k<58) OR (k>64 AND k<90) OR (k>96 AND k<123) THEN GO TO 90
85 PRINT FLASH 1; INK 2; PAPER 7;n;: PRINT INK 9;TAB 5;":";c;TAB 10;v$
90 NEXT j
95 LET p=4+p+le: IF p=v THEN STOP
100 GO TO 20.
9998 SAVE "TRACE" LINE 0

Products

 

Media

 

Image Gallery

Source Code

Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.

Scroll to Top