How would you use the DIM statement to declare ...
How would you use the DIM statement to declare an array in BASIC? Provide an example
Loading lesson…
The DIM statement in BASIC is used to declare arrays by specifying the array's name and dimensions (size). Here's an example of declaring an array of 10 integers:
basic Copy code
DIM numbers(10)
This statement declares an array named numbers with 11 elements (0 to 10) to store integer values.