title: How to get month & day in swift?
body: <p>I want to get the month &amp; date from date as <code>29 NOV</code> in Swift. I have tried below code but this does not work me.</p>
  
  <pre><code> func getMonthfromDate(str_date:String)
    {
      let dateAsString = str_date
      let dateFormatter = DateFormatter()
      dateFormatter.dateFormat = "dd-MM-yyyy"
      let date = dateFormatter.date(from: dateAsString)
      dateFormatter.dateFormat = "dd-mm"
      print("date is \(dateFormatter.string(from: date!))")
  
    }
  
  
  Input-"19-11-2016"
  Output-19:00 
  </code></pre>
  
  <p>Please guide which is right method ?</p>