title: What is the difference between Perl's ( or, and ) and ( ||, && ) short-circuit operators?
body: <p>Which of these subroutines is not like the other?</p>
  
  <pre><code>sub or1 {
      my ($a,$b) = @_;
      return $a || $b;
  }
  
  sub or2 {
      my ($a,$b) = @_;
      $a || $b;
  }
  
  sub or3 {
      my ($a,$b) = @_;
      return $a or $b;
  }
  
  sub or4 {
      my ($a,$b) = @_;
      $a or $b;
  }
  </code></pre>
  
  <p>I came to Perl 5 from C and Perl 4 and always used <code>||</code> until I saw more scripts using <code>or</code> and I liked the way it looked. But as the above quiz shows, it's not without its pitfalls for the unwary. For people who use both constructs or who use a lot of <code>or</code>, what rules of thumb do you use to decide which construct to use and make sure the code is doing what you think it is doing?</p>