title: Perl Regex To Condense Multiple Line Breaks
body: <p>I can't seem to figure out the right syntax but I want a Perl regular expression to find where there are two or more line breaks in a row and condense them into just 2 line breaks.</p>
  
  <p>Here is what I'm using today which doesn't seem to work:</p>
  
  <pre><code>$string =~ s/\n\n+/\n\n/g;
  </code></pre>
  
  <p>Please let me know what I'm doing wrong and the correct Perl regex I should be using.</p>
  
  <p>Thanks in advance for your help!</p>