title: Show AM/PM in capitals in swift
body: <p>I wrote the following code to show a datetime in a particular format:</p>
  
  <pre><code>let formatter = NSDateFormatter()
  formatter.dateStyle = NSDateFormatterStyle.LongStyle
  formatter.timeStyle = .MediumStyle
  formatter.dateFormat = "HH:mm a 'on' MMMM dd, yyyy"
  let dateString = formatter.stringFromDate(newDate!)
  println(dateString)
  </code></pre>
  
  <p>Output</p>
  
  <pre><code>12:16 pm on July 17, 2015
  </code></pre>
  
  <p>I want to show 'pm' as 'PM'(in capitals) and if phone has 24 hours format then AM/PM should not appear. Please help me. </p>