title: Unable to get Date in required SimpleDateFormat
body: <p>Below is the my code for Simple date format.Where iam getting o/p as </p>
  
  <ol>
  <li><code>2012-03-13</code></li>
  <li><code>13:15:00-4:00</code></li>
  <li><code>2012/03/13 13:15:00 +0530</code></li>
  </ol>
  
  <p>but i need the o/p in the format     <code>MM/dd/yyyy HH:mm</code></p>
  
  <pre><code>public class Time {
          public static void main(String args[]) throws ParseException
          {
              SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
              SimpleDateFormat ti=new SimpleDateFormat("MM/dd/yyyy HH:mm");
              SimpleDateFormat sdf1=new SimpleDateFormat("yyyy/MM/dd HH:mm:ss Z");
              String dt=    "2012-03-13T13:15:00-4:00";
  
          String st[]=dt.split("T");
          System.out.println(st[0]);
          System.out.println(st[1]);
  
          String time[]= st[1].split("-");
  
          Date fromDt =(Date)sdf.parse(st[0]+" "+time[0]);
  
  
  
          System.out.println(sdf1.format(fromDt));
  
  
      }
  
  }
  </code></pre>