0
How to assign loops with current time?
In java I want to create a program that can output seperate things depending on time. But don't think that im talking about Random method. it may be like you've input your age and the program will output your date of birth by subtracting your age from the current time. Please help....đ
1 Answer
0
Try using a Date object. Date objects hold the current moment in time as a String, with everything from year, month, and day, to hour and second, including which time zone you are in.
Try playing around with it for a while. Once you have an idea of how to use it, you can then ask for age, and do some math, using the Date object as a reference.
I hope this has helped, and that it wasn't rude...