02-18-2023, 11:07 PM
Quote:after copying and pasting this code into QB64 I have got an "OK" while I was expecting an Error Alert!
Why does QB64 compiler accept the declaration of array with variable as index delimiter?
The reason probably lies in this: A redimensioning takes place because the declaration of the array is not static. QBasic Manual Page 181:
"Dynamic arrays are always created if no constant value is given in the DIM statement - arrays declared as COMMON are also declared dynamically."
Static Arrays:
Const xyz = 100
Dim x(elements)
Dim p(10)
a! (2) = 3.1315 -> Array is implicitly declared static