/* package whatever; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;
import java.text.*;

/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
	public static void main (String[] args) throws java.lang.Exception
	{
		    String dateStr = "Mon Jan 12 00:00:00 IST 2015";

    DateFormat formatter = new SimpleDateFormat("E MMM dd HH:mm:ss Z yyyy");
     DateFormat formatter1 = new SimpleDateFormat("dd.MM.yyyy");
    System.out.println(formatter1.format(formatter.parse(dateStr)));
	}
}