Skip to content

Instantly share code, notes, and snippets.

@yanivpaz
Last active April 15, 2020 10:12
Show Gist options
  • Save yanivpaz/208bd43937617556f3ba68fc2ce6284a to your computer and use it in GitHub Desktop.
Save yanivpaz/208bd43937617556f3ba68fc2ce6284a to your computer and use it in GitHub Desktop.
java date example
import java.time.*;
import java.util.*;
public class HelloWorld {
public static void main(final String[] args) {
long days = System.currentTimeMillis()/1000/60/60/24;
System.out.println("Days since the epoch: "+days);}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment