title: Regex for homework
body: <p>This is for some homework for my beginner class.</p>
  <blockquote>
  <p>An organisation has assigned all clients an identity number. The identity number is of the following format:</p>
  <ul>
  <li><p>2 numeric characters (digits without leading 0s), followed by 3 numeric characters (digits) and 3 numeric characters (digits) separated by a single whitespace</p>
  </li>
  <li><p>or 3 numeric characters (digits without leading 0s) followed by 3 numeric characters (digits) and 3 numeric characters (digits) separated by a single whitespace.</p>
  </li>
  <li><p>any number &lt; 10 000 000 or &gt;150 000 000 is invalid.</p>
  </li>
  </ul>
  </blockquote>
  <p>This is my attempt:</p>
  <pre><code>([\\d]{2}[\\s][\\d]{3}[\\s][\\d]{3})|([\\d]{3}[\\s][\\d]{3}[\\s][\\d]{3})
  </code></pre>
  <p>However the following outputs should not work but they do:</p>
  <pre><code>153 394 111
  943 293 492
  098 302 203
  </code></pre>
  <p>Any help is appreciated. Thank you</p>
  <p>The following are valid inputs:</p>
  <pre><code>11 304 982
  39 683 234
  139 920 393
  </code></pre>
  <p>The following are non valid inputs:</p>
  <pre><code>153 394 111
  3 394 234
  89 909 98
  </code></pre>