import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;
import java.util.Locale;
/* The class name doesn't have to be Main, as long as the class is not public. */
class Main
{
{
Date date1
= simpleDateFormat.
parse(" 2012-08-12T14:18:39.000Z "); String formattedDate
= simpleDateFormat1.
format(date1
); // 20120821 // Date parsedDate = simpleDateFormat1.parse(formattedDate);
System.
out.
println(formattedDate
); }
}
aW1wb3J0IGphdmEudGV4dC5EYXRlRm9ybWF0OwppbXBvcnQgamF2YS50ZXh0LlBhcnNlRXhjZXB0aW9uOwppbXBvcnQgamF2YS50ZXh0LlNpbXBsZURhdGVGb3JtYXQ7CmltcG9ydCBqYXZhLnV0aWwuQ2FsZW5kYXI7CmltcG9ydCBqYXZhLnV0aWwuRGF0ZTsKaW1wb3J0IGphdmEudXRpbC5Mb2NhbGU7CgovKiBUaGUgY2xhc3MgbmFtZSBkb2Vzbid0IGhhdmUgdG8gYmUgTWFpbiwgYXMgbG9uZyBhcyB0aGUgY2xhc3MgaXMgbm90IHB1YmxpYy4gKi8KY2xhc3MgTWFpbgp7CiAgcHVibGljIHN0YXRpYyB2b2lkIG1haW4gKFN0cmluZ1tdIGFyZ3MpIHRocm93cyBqYXZhLmxhbmcuRXhjZXB0aW9uCiAgewoJCSAgICBTaW1wbGVEYXRlRm9ybWF0IHNpbXBsZURhdGVGb3JtYXQgPSBuZXcgU2ltcGxlRGF0ZUZvcm1hdCgieXl5eS1NTS1kZCdUJ0hIOm1tOnNzLlNTUydaJyIpOwoJCSAgICBTaW1wbGVEYXRlRm9ybWF0IHNpbXBsZURhdGVGb3JtYXQxID0gbmV3IFNpbXBsZURhdGVGb3JtYXQoInl5eXlNTWRkIEhIOm1tOnNzICcoWiknIik7CgkJICAgIERhdGUgZGF0ZTEgPSBzaW1wbGVEYXRlRm9ybWF0LnBhcnNlKCIgICAgICAgICAgMjAxMi0wOC0xMlQxNDoxODozOS4wMDBaICAgICAgIik7CgkJICAgIFN0cmluZy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