title: Does the || operator evaluate the second argument even if the first argument is true?
body: <p>I'm trying to evaluate the expression <code>(a=10) || (rr=20)</code> while the rr variable is not defined</p>
  
  <p>so typing <code>rr</code> in the ruby console before evaluating the previous expression returns </p>
  
  <pre><code>rr
  NameError: undefined local variable or method `rr' for main:Object
  from (irb):1
  from :0
  </code></pre>
  
  <p>When I write the expression <code>(a=10) || (rr=20)</code> it returns 10, and when I write rr afterwards it says <code>nil</code></p>
  
  <pre><code>(a=10) || (rr=20)
  rr  # =&gt; nil
  </code></pre>
  
  <p>so, why is this happening? Shouldn't rr be defined only if the second argument of the || operator is evaluated, which should be never based on the documentation?</p>