title: fscanf Giving weird characters in front
body: <p>Whenever I <code>fscanf()</code> from a file, I'm getting weird characters scanned from <code>fscanf()</code>.</p>
  <p>This is the first line of the file I'm trying to scan:</p>
  <pre class="lang-none prettyprint-override"><code>Derek Stevens,9/28/1959
  </code></pre>
  <p>And this is the output that I'm getting after <code>cout</code>'ing everything:</p>
  <pre><code>Birthdate search program
  Name: ∩╗┐Derek Stevens: 16 characters.
  Born: 9281959
  </code></pre>
  <p>Notice the characters in front of <code>Derek</code>.</p>
  <p>This is the function I'm using, the <code>month</code> attribute is not being used yet, that will be used later for sorting.</p>
  <pre><code>bool readBirthDate(int month) {
  
          Employee tempEmployee;
          int nameLength = 0;
          char tempName[256]{};
  
          fscanf(fptr, &quot;%[^,],%d/%d/%d\n&quot;, tempName, &amp;tempEmployee.m_month, &amp;tempEmployee.m_day, &amp;tempEmployee.m_year);
  
          nameLength = strlen(tempName);  
  
          cout &lt;&lt; &quot;Name: &quot; &lt;&lt; tempName &lt;&lt; &quot;: &quot; &lt;&lt; nameLength &lt;&lt; &quot; characters.&quot; &lt;&lt; endl;
          cout &lt;&lt; &quot;Born: &quot; &lt;&lt; tempEmployee.m_month &lt;&lt; tempEmployee.m_day &lt;&lt; tempEmployee.m_year &lt;&lt; endl;
  
          return true;
      }
  </code></pre>