problem with timer
Hi, For the life of me I can't remember how to measure time between two points in the code. I remember doing it a long time ago, where you mark two points in your code then take away the start time from the stop time to get execution time. What is the line of code that measures time in milliseconds?
We've all been there. There are a couple of ways to get the current time in milliseconds. Using the Date class is one them.
Do the same to get the end time and subtract the 2.
Date now = new Date();
long startTime = now.getTime();
Thanks for that!
I just need to measure the time between two points. Its past 3.15 am and I am playing with java. I need life!!.