title: expected array,compile error
body: <pre><code>    For j = 0 To 20
          For i = 0 To 20
  
              ReDim atoms(0 To 20, 0 To 20)
              ReDim atomschange(0 To 20, 0 To 20)
              atomschange(j, i) = 0
  
              If i Mod 2 = 0 And j Mod 2 = 0 Then
                  [B2].Offset(j, i).Interior.ColorIndex = 37
                  atoms(j, i) = 1
              Else
                  [B2].Offset(j, i).Interior.ColorIndex = 36
                  atoms(j, i) = 0
              End If
          Next i
      Next j
  End Sub
  </code></pre>
  
  <p>what am i doing wrong?</p>