fork(1) download
  1. import java.text.DecimalFormat;
  2.  
  3. public class Main {
  4.  
  5. public static void main(String[] args) {
  6. Double timestamp = 1.3552299670232847E12;
  7. System.out.println("it was " + timestamp);
  8. System.out.println("and now " + String.format("%.4f", timestamp));
  9. }
  10.  
  11. }
Success #stdin #stdout 0.03s 246656KB
stdin
Standard input is empty
stdout
it was 1.3552299670232847E12
and now 1355229967023.2847