title: increment and decrement with cout in C++
body: <p>I'm new to C++ and study the increment and decrement operators.
  So I tried this example:</p>
  
  <pre><code>    int x = 4;    
      cout &lt;&lt; ++x &lt;&lt; "    " &lt;&lt; x++ &lt;&lt; "    " &lt;&lt; x++ &lt;&lt; endl &lt;&lt; endl;
      cout &lt;&lt; x &lt;&lt; endl;
  </code></pre>
  
  <p>It returns this <em>weird</em> output on C++ .NET and QtCreator and 5 online C++ compilers:</p>
  
  <pre><code>7    5    4
  
  7
  </code></pre>
  
  <p>The <em>weird</em> thing is that I expect something like this:</p>
  
  <pre><code>5    5    6
  
  7
  </code></pre>
  
  <p>Can you explain what happens?</p>