title: Convert date with format dd.mm.yy to yyyy-mm-dd in python
body: <p>I have a date with format:</p>
  
  <pre><code>    d1 = "22.05.15"
  </code></pre>
  
  <p>I want to change to date with format:</p>
  
  <pre><code>    d1 = "2015-05-22"
  </code></pre>
  
  <p>I tried converting using datetime:</p>
  
  <pre><code>    d2 = datetime.strptime(d1,'%d.%m.%Y').strftime('%Y-%d-%m')
  </code></pre>
  
  <p>But, it does not work because datetime does not support date with format '22.05.15' but only '22.05.2015'</p>
  
  <p>Is there any way out to convert date of such format ?</p>