Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.text.DateFormat;
import java.util.Date;

public class Main {
    public static void main(String[] args) {
        try {
            String target = "Thu Sep 28 20:29:30 JST 2015";
            DateFormat df = new SimpleDateFormat("EEE MMM dd kk:mm:ss zzz yyyy");
            Date result = df.parse(target);
            System.out.println(result);
        } catch (ParseException pe) {
            pe.printStackTrace();
        }
    }
}