Advertisement
plirof2

Sinclair Basic Error Codes

May 19th, 2022 (edited)
468
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. 1 REM https://worldofspectrum.org/forums/discussion/14410/little-basic-game
  2.  
  3. Try TO make all standard BASIC-errors AND tell us how you did it.
  4. NOT allowed i.e. :
  5.  
  6. PRINT USR 1362
  7. D - Break cont-repeats
  8.  
  9. but ok
  10. 10 GO TO 10
  11. RUN AND press BREAK
  12. D - Break cont-repeats
  13.  
  14. 10 LET x=0
  15. 20 NEXT x
  16. RUN
  17. [B]1 NEXT without FOR, 20:1[/B]
  18.  
  19. 10 NEXT x
  20. RUN
  21. [B]2 Variable NOT found, 10:1[/B]
  22.  
  23. 10 DIM a(5)
  24. 20 PRINT a(6)
  25. RUN
  26. [B]3 Subscript wrong, 20:1[/B]
  27.  
  28. DIM a(50000)
  29. [B]4 Out of memory, 0:1[/B]
  30.  
  31. PRINT AT 22,0;"Error"
  32. [B]5 Out of screen, 0:1[/B]
  33.  
  34. PRINT 10^39
  35. [B]6 Number too big, 0:1[/B]
  36.  
  37. RETURN
  38. [B]7 RETURN without GOSUB, 0:1[/B]
  39.  
  40. 10 STOP
  41. RUN
  42. [B]9 STOP statement, 10:1[/B]
  43.  
  44. PRINT USR "z"
  45. [B]A Invalid argument, 0:1[/B]
  46.  
  47. DIM a(70000)
  48. [B]B INTEGER out of range, 0:1[/B]
  49.  
  50. SAVE "Long File Name"
  51. [B]C Nonsense in BASIC, 0:1[/B]
  52.  
  53. READ a
  54. [B]E Out of DATA, 0:1[/B]
  55.  
  56. 10 SAVE ""
  57. RUN
  58.  
  59. [b]F Invalid file name, 10:1[/b]
  60.  
  61. Reset
  62. CLEAR 23860
  63. >type 10 PRINT AND press enter.
  64.  
  65. [b]G No room FOR line, 0:1[/b]
  66.  
  67. 10 INPUT a$
  68. RUN
  69. >input STOP, press Enter.
  70. (I guess there were two alternate method TO DO that.)
  71. [b]H STOP in INPUT[/b]
  72.  
  73. 10 FOR I=1 TO 0
  74. RUN
  75.  
  76. [b]I FOR without NEXT, 10:1[/b]
  77.  
  78. 10 INPUT #3,a
  79. RUN
  80. [b]J Invalid I/O device, 10:1[/b]
  81.  
  82. 10 BORDER 9
  83. RUN
  84.  
  85. [B]K Invalid colour, 10:1[/b]
  86.  
  87.  
  88. 10 GO TO 10
  89. RUN
  90. Press BREAK
  91.  
  92. L BREAK into program, 10:1
  93.  
  94.  
  95. CLEAR 1
  96.  
  97. M RAMTOP no good, 0:1
  98.  
  99. 10 STOP
  100. RUN
  101. 10 (delete line)
  102. CONTINUE
  103.  
  104. N Statement Lost, 0:1
  105.  
  106. LOAD""
  107. Play any tape AND stop it during the loading of a block
  108.  
  109. R Tape Loading Error, 0:1
  110.  
  111. That leaves four TO GO (I think).
  112.  
  113. ___________
  114. OPEN #16, "P"
  115.  
  116. O Invalid stream, 0:1
  117.  
  118. PRINT FN a() : REM with no program
  119.  
  120.  
  121. P FN without DEF FN, 0:1
  122.  
  123. 10 DEF FN a(x) = 1 : PRINT FN a (2,3)
  124. RUN
  125.  
  126. Q Parameter error, 10:2
  127.  
  128. may i CONTINUE? :grin:
  129.  
  130. SAVE ! "a" SCREEN$
  131. LOAD ! "a"
  132.  
  133. b Wrong file type
  134.  
  135. PLAY "((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((a))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))"
  136.  
  137. d Too many brackets
  138.  
  139. SAVE ! "a"
  140. SAVE ! "a"
  141.  
  142. e File already exists
  143.  
  144. ERASE ! ""
  145.  
  146. f Invalid name
  147.  
  148. No g?
  149.  
  150. Reset speccy
  151. LOAD ! "b"
  152.  
  153. h File does NOT exist
  154.  
  155. FORMAT "";0
  156.  
  157. i Invalid device
  158.  
  159. FORMAT "p";0
  160.  
  161. j Invalid baud rate
  162.  
  163. PLAY "k"
  164.  
  165. k Invalid note name
  166.  
  167. PLAY "V100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"
  168.  
  169. l Number TO big
  170.  
  171. PLAY "O7##########################################################################B"
  172.  
  173. m Note out of range
  174.  
  175. PLAY "V100"
  176.  
  177. n Out of range
  178.  
  179. AS FOR the others:
  180.  
  181. a I dont have a clue how TO get
  182.  
  183. c - I tried
  184. 10 SAVE ! "a" 1,60000
  185. 20 LOAD ! "a" 50000,60000
  186.  
  187. AND my computer exploded, but i didn't get the error message though
  188.  
  189. g - I don't know if it even exists
  190.  
  191. o - I tried
  192. 10 LET a$="2"
  193. 20 FOR i=1 TO 2000
  194. 30 LET a$=a$+"_2"
  195. 40 NEXT i
  196. 50 LET a$=a$+"c"
  197. 60 PLAY a$
  198.  
  199. 10 SAVE INKEY$ CODE CODE INKEY$, CODE INKEY$
  200.  
  201. might give:
  202. F Invalid file name, 10:0
  203.  
  204. _________
  205. POKE 23610,28
  206.  
  207. T ? 1982 Sinclair Research Ltd, 0:1
  208.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement