title: C++ i+=1 shortcut to i=i+1?
body: <p>I have a program set up right below. </p>
  
  <pre><code>for (int i = 0; i &lt;= 10; i += 1) {
      cout &lt;&lt; "+= " &lt;&lt; i &lt;&lt; endl;
  }
  cout &lt;&lt; endl;
  for (int i = 0; i &lt;= 10; i = i + 1) {
      cout &lt;&lt; "+ " &lt;&lt; i &lt;&lt; endl;
  }
  </code></pre>
  
  <p>I assume += 1 is a shortcut for i = i + 1 because I can't just do
  (i = 0; i &lt;= 10; i + 1), that just takes i, which is zero, and adds a one which makes a sum of just one. It does not actually do anything to i during the loop.</p>
  
  <p>I'm sorry if I just answered my own question, I probably did but I couldn't find an answer anywhere else, and I just want to make sure.</p>