Java tutorial
import java.util.Calendar; import java.util.Formatter; public class Main { public static void main(String[] argv) throws Exception { Formatter fmt = new Formatter(); Calendar cal = Calendar.getInstance(); System.out.println(fmt.format("Short date format: %tD\n", cal)); } } //Short date format: 03/09/09