title: Regex match string that end with character but exclusive of that character
body: <p>I need to match the quality of a film and order them. The value can be found in the title</p>
  
  <p>Ex. <code>"The Wolf of Wall Street (2014) (HD, 1080p).mov"</code></p>
  
  <p>I have a regex that matches the quality:</p>
  
  <pre><code>"\\d\\d\\d[\\d]*p"
  </code></pre>
  
  <p>For some reason when i compare (compareTo) the values they are ordered:</p>
  
  <p>Ex.</p>
  
  <pre><code>1080p
  1080p
  480p
  480p
  480p
  720p
  720p
  </code></pre>
  
  <p>480p lists higher than 720p. I believe that this happens because of the p(?). I wonder how I can change my regex to check that there is a p (so the year in the title isn't matched, only the quality) but excludes the p in the matched string.</p>