title: Setting class level 2D Array variable to passed in value - C++
body: <p>I'm attempting to make a maze-solving program, and while the algorithm is sound (at least in my head), I've been running into a roadblock with 2D arrays.  I'm coming from C# and Java, so the syntax is giving me grief.</p>
  
  <p>Here's an SSCCE:</p>
  
  <pre><code>//Main.cpp
  
  #include "MazeSolver.h"
  
  int main()
  {
       MazeSolver mazeSolver;
  
       char maze[51][51] = { }; // Not bothering to show code for populating the array
  
       mazeSolver.setMaze(maze);
  }
  </code></pre>
  
  <hr>
  
  <pre><code>//MazeSolver.cpp
  
  #include "MazeSolver.h"
  
  MazeSolver::MazeSolver() { }
  
  void MazeSolver::setMaze(char maze[51][51])
  {
       this-&gt;maze = maze;
  }
  </code></pre>
  
  <hr>
  
  <pre><code>//MazeSolver.h
  
  #ifndef _MAZESOLVER_H
  #define _MAZESOLVER_H
  
  class MazeSolver
  {
  private:
       char **maze; // This is likely the problem, I'm at wits end in regards to
                    // what notation is needed here.  I do not want to hard-copy
                    // the entire array, I just need to access it (via pointer)
                    // I've also tried just using char maze[51][51] here, char *maze, etc...
  public:
        MazeSolver();
        void setMaze(char maze[51][51]);
  }
  </code></pre>