title: Why are my strings not printing correctly in C++?
body: <p>I have a simple program as follows:</p>
  
  <pre><code>#include &lt;iostream&gt;
  
  using namespace std;
  
  int main()
  {
      int N;
      cout &lt;&lt; "Enter N: " &lt;&lt; endl;
      cin &gt;&gt; N;
      int acc = 0;
  
      cin &gt;&gt; acc;
      int min = acc;
      int max = acc;
  
  
      for (int i=1; i&lt;N; i++) {
          int current;
          cin &gt;&gt; current;
          acc += current;
          if (current &gt; max) {
              max = current;
          } else if (current &lt; min) {
              min = current;
          }
      }
  
      cout &lt;&lt; "Total: " + acc &lt;&lt; endl;
      cout &lt;&lt; "Max: " + max &lt;&lt; endl;
      cout &lt;&lt; "Min: " + min &lt;&lt; endl;
      return 0;
  }
  </code></pre>
  
  <p>My output is getting chopped off as follows</p>
  
  <pre><code>./stat
  Enter N:
  3
  1
  2
  3
  
  :
  in:
  </code></pre>
  
  <p>What am I doing wrong?  </p>