title: Calling a method to fill a 2d array in C#
body: <p>I am a very new programmer, and have been struggling to write a method that can        take any 2D array and fill it with random integers from 1 to 15. I believe I managed to build my method correctly, but I can't seem to see how to then call my method to fill the array I made in main. (I would have just filled it in main right out, but I'm trying to practice methods as well.) Here is the code I have so far. I appreciate any help you all are able to give me, thanks!</p>
  
  <pre><code>using System;
  using System.Collections.Generic;
  using System.Linq;
  using System.Text;
  using System.Threading.Tasks;
  
  namespace Homework2
  {
  class Program
  {
      static void Main(string[] args)
      {
          int[,] myArray = new int[5,6];
      }
  
      public int[,] FillArray (int i, int j)
      {
          Random rnd = new Random();
          int[,] tempArray = new int[,]{};
          for (i = 0; i &lt; tempArray.GetLength(0); i++)
          {
              for (j = 0; j &lt; tempArray.GetLength(1); j++)
              {
                  tempArray[i, j] = rnd.Next(1, 15);
              }
          }
          return tempArray;
      }
  }
  </code></pre>
  
  <p>}</p>