title: Regex: how to detect a particular text, followed by a specific number?
body: <p>I want to use regex for the following statements:</p>
  
  <ul>
  <li>What are the <strong>top 10</strong> destination?</li>
  <li>What are the <strong>top 5</strong> destinations?</li>
  <li>What are the <strong>bottom 10</strong> destination?</li>
  <li>What are the <strong>bottom 7</strong> destinations?</li>
  </ul>
  
  <p>How can I write regex for the above cases where <em>first</em> it detects if the user wants "top" or "bottom" destinations <em>and then</em> checks the quantity i.e 10 or 7 or 5?</p>
  
  <p>I'm trying the following which isn't working.</p>
  
  <pre><code>(?&lt;top&gt;\d{2})
  (?&lt;bottom&gt;\d{2})
  </code></pre>
  
  <p>Basically, the idea is if the user types top 10 destinations, the system will trigger a response e.g.</p>
  
  <pre><code>console.log("you want top 10 destinations")
  </code></pre>