title: Reading in multiple data types from a text file into a class object C++
body: <p>I have a text file of prisoner records:</p>
  
  <p>Roy MOYES ARSON 35</p>
  
  <p>Damien SIEBERT OTHER 37</p>
  
  <p>Nigel COMYN ROBBERY 46 59000</p>
  
  <p>Gai CRABBE OTHER 95</p>
  
  <p>Stacey BEGLEY OTHER 80</p>
  
  <p>I am trying to read this into a class object of prisoner:</p>
  
  <pre><code>void Prison::ReadCrimFile(){
  ifstream fin;
  fin.open("crims.txt");
  if(!fin.good())
      cerr &lt;&lt; "File not found!\n" &lt;&lt; endl;
  else
      while(!fin.eof()){
          fin &gt;&gt; FirstName &gt;&gt; FamilyName &gt;&gt; Crime &gt;&gt; Months;
          Criminal* C = new Criminal(FirstName, FamilyName, Crime, Months, i);
          Crims.insert(C);
      }
      fin.close();
      cout &lt;&lt; "There are" &lt;&lt; " " &lt;&lt; Crims.size() &lt;&lt; " " &lt;&lt;"criminals on 
  record" &lt;&lt; endl;
  }
  </code></pre>
  
  <p>When I run it though it doesn't produce any output at the end, there's just blinking cursor in the console window</p>