title: How to compare date and time using comparison operator in c++
body: <p>I have a string read in and it is separated to year, month, day, hour, minute, second, millisecond. I want to be able to compare two different date/ time stamps. Ex. Check if hour on lhs is larger then hr on rhs. and then continue to check months, days, hours, minutes, seconds, and milliseconds. So far I have and idea of what I'm trying to do just having a hard time putting it together. If anyone has any ideas that would be awesome. Ps. this is NOT a homework assignment, I'm in the process of building an application, while learning c++. </p>
  
  <pre><code>ClassName operator &lt; (ClassName &amp;lhs, ClassName &amp;rhs);
  </code></pre>
  
  <p>above is function.</p>
  
  <p>Thanks!</p>