import java.text.DateFormat;
import java.util.Date;
import java.util.Locale;
public class MainClass {
public static void main(String[] args) {
Date today = new Date();
DateFormat fmt = DateFormat.getDateTimeInstance(DateFormat.FULL,
DateFormat.FULL, Locale.US);
String formatted = fmt.format(today);
System.out.println(formatted);
}
}
Tuesday, January 16, 2007 10:03:23 AM PST