Java: Filling two-dimensional array from input file
<p>Basically, I need to scan this (from an input .txt file):</p>

<pre><code>oooooooo
#S#ooooo
oo#oo##o
ooo#ooo#
oo#oo$oo
o######o
oooooooo
</code></pre>

<p>Into a two-dimensional array.  Here's what I have so far:</p>

<pre><code>public static void main(String[] args) throws IOException
{
    Scanner scan = new Scanner(new File("inputFile.txt"));
    numRows = scan.nextInt();
    numColumns = scan.nextInt();
    mazeArray = new char[numRows][numColumns];


    for(int row = 0; row &lt; numRows; row++)
    {
        strings = scan.next();

        for(int column = 0; column &lt; numColumns; column++)
        {
            mazeArray[row][column] = strings.charAt(row);
            System.out.print(mazeArray[row][column]);
        }
        System.out.print("\n");
    }
}
</code></pre>

<p>The output is all wrong:</p>

<pre><code>oooooooo
SSSSSSSS
########
########
oooooooo
########
oooooooo
</code></pre>
