title: Initialising a multidimensional array in Java
body: <p>What is the correct way to declare a multidimensional array and assign values to it?</p>
  
  <p>This is what I have:</p>
  
  <pre><code>int x = 5;
  int y = 5;
  
  String[][] myStringArray = new String [x][y];
  
  myStringArray[0][x] = "a string";
  myStringArray[0][y] = "another string";
  </code></pre>