title: array reference expected exception in java
body: <p>Im just trying to create a new 2d array using existing 2d array call <code>properties</code> and new two values which is <code>sourceURL</code> and <code>fetchURL</code>. </p>
  
  <pre><code>public static String[][] setProperties(String[][] properties, String sourceURL, String fetchURL) {
          String[][] propertyArray = new String[properties.length][];
          for (int i = 0; i &lt;= properties.length; i++) {
              if (i &lt; properties.length) {
                  propertyArray[i][0] = properties[i][0];
                  propertyArray[i][1] = properties[i][1];
              } else {
                  propertyArray[properties.length][0] = sourceURL;
                  propertyArray[properties.length][1] = fetchURL;
                  return propertyArray;
              }
          }
          return new String[0][];
      }
  </code></pre>
  
  <p>while I'm doing this I'm getting an exception saying "array reference expected" in the <code>propertyArray[i][0] = properties[i][0];</code> line. Can some one help me to create this function?</p>