title: What's the difference between 'eq' and '=~' in Perl?
body: <p>What is the difference between these two operators?  Specifically, what difference in <code>$a</code> will lead to different behavior between the two?</p>
  
  <pre><code>$a =~ /^pattern$/
  
  $a eq 'pattern'
  </code></pre>