title: How to increment an integer in Ruby
body: <p>What causes the error in the following code?</p>
  
  <pre><code>ruby -e "puts 1++"
  -e:1: syntax error, unexpected $end
  </code></pre>
  
  <p>or </p>
  
  <pre><code>ruby -e "x=1; puts x++;"
  -e:1: syntax error, unexpected ';'
  </code></pre>