08-07-2017, 08:42 AM
ivanb303 Wrote:It does work even without the --sinclair compile option, but you have to change the indexes in the array around. The old does theYes. In "modern" Basic (see FreeBASIC) arrays starts from 0 like in C. This is slightly faster and simplifies some programs.
array index start from 1 or 0
You can explicitly tell the compiler to start from 1. For example an array from 1 TO 8 will be:
Code:
DIM myArray(1 TO 8)
If you're starting from scratch, the modern BASIC dialect is recommended. ZX Basic tries to follow Visual Basic / FreeBasic dialects as much as possible.