PyMOTW: datetime

The datetime module includes functions and classes for doing date parsing, formatting, and arithmetic. Time values are represented with the time class. Times have attributes for hour, minute, second, and microsecond. They also, optionally, include time zone information. The arguments to initialize a time instance are optional, but the default of `` is unlikely to be what you want.

Read more at pymotw.com: datetime