+ 3
Get time java
How can I get current date and time in java?
3 Respuestas
+ 5
You should import java.util.Date
+ 3
System.out.print(new java.util.Date());
+ 2
You can do it with this:
Date date = new Date();
Or this:
System.currentTimeMillis();
Just how Airree mentioned; you have to import the Date library