title: Reading from TextFile in C++
body: <p>I am a java/C# developer and i am trying to write a C or C++ code to read data from a text file. this is very easily done in java and c# but not in c or c++.  </p>
  
  <p>the textfile i am reading looks like this:</p>
  
  <pre><code>a,b,c,d,e
  1,0,1,1,0
  0,1,1,0,0
  0,0,0,1,1
  </code></pre>
  
  <p>i need to store the values in 2 arrays.<br>
  the 1st one is a 1D char array which will contain: <code>a b c d e</code><br>
  the 2nd one is a 2D bool array which will contain:  </p>
  
  <pre><code>  1 0 1 1 0
    0 1 1 0 0
    0 0 0 1 1
  </code></pre>
  
  <p>how can i do this?</p>