title: ruby boolean operator or || difference
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/2083112/ruby-difference-between-and-or">Ruby: difference between || and &#39;or&#39;</a>  </p>
  </blockquote>
  
  
  
  <p>In ruby, isn't 'or' and '||' the same thing? I get different results when I execute the code.</p>
  
  <pre><code>line =""
  if (line.start_with? "[" || line.strip.empty?)
    puts "yes"
  end
  
  
  
  
  line =""
  if (line.start_with? "[" or line.strip.empty?)
    puts "yes"
  end
  </code></pre>