title: Regular expression to validate decimal numbers
body: <p>The regular expression should match below criteria. The number of elements before and after the dot can be any. Only 1 dot is allowed and negative sign is allowed at first position only. I do not require comma.</p>
  
  <p>Example:</p>
  
  <pre><code>1
  -1
  -1.
  1.
  1.2
  -.2
  -0.2
  000.300
  </code></pre>
  
  <p>All above expressions should result true. </p>
  
  <p>So if i break up.. </p>
  
  <ol>
  <li>An optional negative sign at first place.</li>
  <li>Zero or more digit before dot.</li>
  <li>Dot is optional. Can occur max one time. It can be pure integer number also.</li>
  <li>O or more digits after dot.</li>
  </ol>
  
  <p>Any help will be appreciated.</p>