Arrays....

Blitz3D Forums/Blitz3D Beginners Area/Arrays....

think of mine sweeper. i'm sure that uses an array. the way i think of it is a grid. an array can have many dimentions.

it basically allows you to refer to a variable dynamically.

think of the minesweeper game.

dim minegrid(10,10)


this will basically set up an array (a grid) 10 wide by 10 high.

this has many advantages. 1st being if you want to clear the grid for some reason, you would use 2 loops to clear all the values.

for loop=0 to 10
   for loop1=0 to 10
      minegrid(loop,loop1)=0
   next
next


this would clear the entire grid. think of doing that not using arrays. would be very painful

minegrid_0_0=0
minegrid_0_1=0
minegrid_0_1=0
minegrid_0_2=0
....
....


would take alot of lines to do that, never mind accessing a particular variable. hope some of this helps, mustangs link is very good too :D