I am doing a program where I build a two-dimensional array and then populate it with elements by using a random number generator. It is supposed to have random numbers between 1 and 100. I keep getting a compiler error saying that I have the wrong number of dimensions. Is this something about the way I set up the array or is it the code for the random number generator? This is what I have so far:

Dim x(1 To 5, 1 To 10) As Single
Dim n As Long, i As Long
For i = 1 To 5
x(i) = Int(Rnd * 100) + 1
Next i
For i = 1 To 5
Print i, x(i)
Next i
For n = 1 To 10
x(n) = Int(Rnd * 100) + 1
Next n
For n = 1 To 10
Print n, x(n)
Next n