Skip to content

Instantly share code, notes, and snippets.

@Baneeishaque
Created May 20, 2017 03:12
Show Gist options
  • Save Baneeishaque/6f8cbcdcb74a646d99f4679ec61839d7 to your computer and use it in GitHub Desktop.
Save Baneeishaque/6f8cbcdcb74a646d99f4679ec61839d7 to your computer and use it in GitHub Desktop.
Unix_Timestamp_Conversion.java
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package unix_timestamp_conversion;
import java.util.Date;
/**
*
* @author dk
*/
public class Unix_Timestamp_Conversion {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
// TODO code application logic here
long timeStamp = 1492358400;
Date time=new Date((long)timeStamp*1000);
System.out.println(time);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment