Format

Date and Time

Introduction: This page will teach you about using the Date import in Java to output or get the current Time and/or Date. When is this needed? Adding a simple clock or date counter to an application adds a slightly more professional look to the overall appeal of the program, as well as having the time handy is always a good thing. What imports are needed? The imports we need to get the current Date and Time are;
  1. import