title: Do calculations on datetime in Python
body: <p>I've been trying the following date&amp;time operations: </p>
  
  <pre><code>import datetime
  a = datetime.datetime.strptime("1899-12-30 19:45:00", "%Y-%m-%d %H:%M:%S")
  b = datetime.datetime.strptime("1899-12-30 12:42:00", "%Y-%m-%d %H:%M:%S") 
  print (a-b)
  print (a/b)
  </code></pre>
  
  <p>a-b works super, but a/b crashes: TypeError: unsupported operand type(s) for /: 'datetime.datetime' and 'datetime.datetime'</p>
  
  <p>Any ideas on how I can calculate relations between date&amp;time-values? Do I need to explicitly first calculate the seconds in each variable a and b, or is there a shorter short cut?</p>
  
  <p>And if I need to calculate seconds. How do I do it? I've tried</p>
  
  <pre><code>s = a.total_seconds()
  which gives: AttributeError: 'datetime.datetime' object has no attribute 'total_seconds'
  </code></pre>
  
  <p>(I'm using Python 3.3)</p>