title: JavaScript calculate the day of the year (1 - 366)
body: <p>How do I use JavaScript to calculate the day of the year, from 1 - 366?</p>
  <p>For example:</p>
  <ul>
  <li><code>January 3</code> should be <code>3</code>.</li>
  <li><code>February 1</code> should be <code>32</code>.</li>
  </ul>