The following warnings occurred:
Warning [2] Undefined array key 0 - Line: 1677 - File: showthread.php PHP 8.2.31 (Linux)
File Line Function
/inc/class_error.php 157 errorHandler->error
/showthread.php 1677 errorHandler->error_callback
/showthread.php 916 buildtree




Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to manage part of a STRING?
#1
In standard Basic, we have this example correctly working:

Code:
10 LET a$="123456789012345678901234567890xy" 20 PRINT AT 0,0; a$ 30 IF INKEY$="0" THEN LET a$=a$(32) + a$(1 TO 31) 40 GOTO 20

...but it doesn't seem to work in ZXB:

Code:
DIM test AS STRING test="123456789012345678901234567890xy" mainloop: PRINT AT 0,0; test IF INKEY="0" THEN test=test(32) + test(1 TO 31) END IF GOTO mainloop

Thoughts?
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)