title: How to extract group of numbers from a phrase using regex?
body: <p>I have multiple sentences which look like the following sentence - 
  <code>069054 my name is black fox, $1234. phone number:1234567</code></p>
  
  <p>I need to extract to extract the first word (or numbers, in this example its 069054).</p>
  
  <p>The conditions that needs to be met are:</p>
  
  <ol>
  <li>it should only consist of 6 digits.</li>
  <li>It should be the first thing in the sentence.</li>
  <li>If it has more or less digits, i should ignore it.</li>
  <li>should only consist of numbers, no chars allowed</li>
  </ol>
  
  <p>Here is what i have, but its not working out for me. </p>
  
  <pre><code>^([\d]{6})$
  </code></pre>