| integer | real | string | |
| example | 346 | 9.847 | "HELLO" |
| typical variables | A% | A | A$ |
| name | SIZE% | SIZE | SIZE$ |
| max size | 2,147,483,647 | 1.7x1038 | 255 chars |
| accuracy | 1 digit | 9 sig figs | - |
| stored in | 32 bits | 40 bits | ASCII values |
| Two colour modes (0,3,4,6) | ||
| foreground | background | default colour |
| 0 | 128 | black |
| 1 | 129 | white |
| Four colour modes (1,5) | ||
| foreground | background | default colour |
| 0 | 128 | black |
| 1 | 129 | red |
| 2 | 130 | yellow |
| 3 | 131 | white |
| Mode 2 - 16 colour mode | ||
| foreground | background | default colour |
| 0 | 128 | black |
| 1 | 129 | red |
| 2 | 130 | yellow |
| 3 | 131 | white |
| 4 | 132 | black |
| 5 | 133 | red |
| 6 | 134 | yellow |
| 7 | 135 | white |
| 8 | 136 | black |
| 9 | 137 | red |
| 10 | 138 | yellow |
| 11 | 139 | white |
| 12 | 140 | black |
| 13 | 141 | red |
| 14 | 142 | yellow |
| 15 | 143 | white |
100 DEF FNVAT(number)=1.175*number
110 a = FNVAT(100)
100 DEF PROCINIT(X)
110 REM clears screen
120 COLOUR 128+X
130 CLS
140 ENDPROC
| parameter | range | function |
| N | 1 to 4 | envelope number |
| T bits 0-6 | 0 to 127 | length of each step in hundredths of seconds |
| T bit 7 | 0 or 1 | 0 - auto repeat, 1 - don't autorepeat |
| PI1 | -128 to 127 | change of pitch per step in section 1 |
| PI2 | -128 to 127 | change of pitch per step in section 2 |
| PI3 | -128 to 127 | change of pitch per step in section 3 |
| PN1 | 0 to 255 | number of steps in section 1 |
| PN2 | 0 to 255 | number of steps in section 2 |
| PN3 | 0 to 255 | number of steps in section 3 |
| AA | -127 to 127 | change of amplitude per step during attack phase |
| AD | -127 to 127 | change of amplitude per step during decay phase |
| AS | -127 to 0 | change of amplitude per step during sustain phase |
| AR | -127 to 0 | change of amplitude per step during release phase |
| ALA | 0 to 126 | target of level at end of attack phase |
| ALD | 0 to 126 | target of level at end of decay phase |
10 wrong = ERR
100 IF ERR=17 THEN PRINT "YOU CAN'T ESCAPE"
1000 DEF FNmean(x,y) = (x+y)/2
| 0 | plot the colour specified |
| 1 | OR specified colour with the one that is already there |
| 2 | AND specified colour with the one that is already there |
| 3 | XOR specified colour with the one that is already there |
| 4 | invert the colour already there |
| Key | Number | Key | Number |
| f0 | -33 | 1 | -49 |
| f1 | -114 | 2 | -50 |
| f2 | -115 | 3 | -18 |
| f3 | -116 | 4 | -19 |
| f4 | -21 | 5 | -20 |
| f5 | -117 | 6 | -53 |
| f6 | -118 | 7 | -37 |
| f7 | -23 | 8 | -22 |
| f8 | -119 | 9 | -39 |
| f9 | -120 | 0 | -40 |
| A | -66 | 0 | -24 |
| B | -101 | \ | -25 |
| C | -83 | \ | -121 |
| D | -51 | @ | -72 |
| E | -35 | [ | -57 |
| F | -68 | _ | -41 |
| G | -84 | ; | -88 |
| H | -85 | : | -73 |
| I | -38 | ] | -89 |
| J | -70 | ' | -103 |
| K | -71 | . | -104 |
| L | -87 | / | -105 |
| M | -102 | ESCAPE | -113 |
| N | -86 | TAB | -97 |
| O | -55 | CAPSLOCK | -65 |
| P | -56 | CTRL | -2 |
| Q | -17 | SHIFT LOCK | -81 |
| R | -52 | SHIFT | -1 |
| S | -82 | SPACEBAR | -99 |
| T | -36 | DELETE | -90 |
| U | -54 | COPY | -106 |
| V | -100 | RETURN | -74 |
| W | -34 | CRSR UP | -58 |
| X | -67 | CRSR DOWN | -42 |
| Y | -69 | CRSR LEFT | -26 |
| Z | -98 | CRSR RIGHT | -122 |
letter$=INKEY$(100) waits 100 centi-seconds
INPUT "Your age",AGE or INPUT "Input three numbers", A, B, C
INPUT# channel, name$, age$
a$ = left$(test,3) would assign "tes" to a$
List n would list line number n. List ,n would list from start to n. List n, would list from n to end. List n,m would list from n to m.
| Mode | Graphics | Colours | Text |
| 0 | 640x256 | 2 colour display | 80x32 text |
| 1 | 320x256 | 4 colour display | 40x32 text |
| 2 | 160x256 | 16 colour display | 20x32 text |
| 3 | 2 colour text only | 80x25 text | |
| 4 | 320x256 | 2 colour display | 40x32 text |
| 5 | 160x256 | 4 colour display | 20x32 text |
| 6 | 2 colour text only | 40x25 text | |
| 7 | Teletext | 40x25 text |
| 0 | move relative to last point. |
| 1 | draw line relative in the current graphics foreground colour. |
| 2 | draw line relative in the logical inverse colour |
| 3 | draw line relative in current graphics background colour |
| 4 | move to absolute position |
| 5 | draw line absolute position |
| 6 | draw line absolute in logical inverse colour |
| 7 | draw line absolute in curent graphics background colour |
| 8-15 | as 0-7 but with the last point in the line omitted to avoid inverting actions |
| 16-23 | as 0-7 but with a dotted line |
| 24-31 | as 0-7 but with a dotted line and the last point omitted. |
| 32-63 | reserved for the Graphics Extension ROM |
| 64-71 | as 0-7 but only a single point is plotted |
| 72-79 | reserved |
| 80-87 | as 0-7 but plot and fill a triangle. Fills between current x,y and last two points visited. |
| 88-255 | reserved |