Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
12
Task/Show-the-epoch/Java/show-the-epoch.java
Normal file
12
Task/Show-the-epoch/Java/show-the-epoch.java
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
import java.text.DateFormat;
|
||||
import java.util.Date;
|
||||
import java.util.TimeZone;
|
||||
|
||||
public class DateTest{
|
||||
public static void main(String[] args) {
|
||||
Date date = new Date(0);
|
||||
DateFormat format = DateFormat.getDateTimeInstance();
|
||||
format.setTimeZone(TimeZone.getTimeZone("UTC"));
|
||||
System.out.println(format.format(date));
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue