title: How to declare the Char array of char variables already declared in class?
body: <pre><code>#include &lt;stdio.h&gt;
  #include &lt;iostream&gt;
  
  using namespace std;
  
  //char* b[6] = new char[6];
  
  char a[6] = {'b','c','d','e','f','g'};
  char c[6] = {'a','b','d','d','f','g'};
  
  int main()
  {
      char d[][6]={*a,*c};
  
  
  
      for (int x = 0 ; x &lt; 1; x++)
      {
          for(int y = 0; y&lt;6; y++)
          {
              char test = d[x][y];
              cout &lt;&lt; test &lt;&lt;"\n";
          }
      }
      return 0;
  }
  </code></pre>
  
  <p>This code is C++ code. I am trying to create a class where it stores the char array. Then there is another char array of array storing already declared char variables. It compiles fine but it doesn't work out to as it should. It doesn't get me the right value that it should when the program tries to print the value</p>