I want to format a date from Sun Apr 10 07:05:45 MDT 2017
to 2017-04-10T07:05:45.24Z
.
I am using the following:
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("EEE-LLL-dd H:mm:sszuuuu");
formatter.parse(date);
date is in the format given above.
But I am getting a parse error at index 3