title: Figure out if hours spanned is greater than 24
body: <p>I don't know if am am loosing my mind or if this is even possible.</p>
  
  <p>By the way, I am not using any standard libraries so this is not language dependent, hence why it's here and not on stackoverflow.</p>
  
  <p>I have 2 time periods that are being passed to me in a int format.</p>
  
  <pre><code>1st period-
      Start Time:
      End Time:
  
  2nd period-
      Start Time:
      End Time:
  </code></pre>
  
  <p>The Int's are minutes since midnight, so 7am would be 420 minutes.</p>
  
  <p>So an example of a function I am trying to write is:</p>
  
  <pre><code>bool SpanMoreThan24Hours(int firstStartTime, int firstEndTime,
                           int secondStartTime, int secondEndTime)
  {
      ....
  }
  </code></pre>
  
  <p>I am not even sure this can be done.</p>
  
  <p>P.S. Spanning midnight is fine, but it doesn't have to.
  Periods can't overlap.</p>
  
  <pre><code>So it could look like this:
  420, 1140, 1260, 419
  7am, 7pm,  9pm,  6:59am
  - Valid
  This would be valid since it doesn't span over 24 hours.
  
  420, 1140, 1260, 421
  7am, 7pm,  9pm,  7:01am
  - Not valid
  
  420, 60, 120, 419
  7am, 1am,2am, 6:59am
  - Valid
  </code></pre>
  
  <p>I have to make sure from 1st period start time till 2nd period end time is not over 24 hours.</p>