Created
November 1, 2013 01:00
-
-
Save h4ck4life/7259621 to your computer and use it in GitHub Desktop.
Java Code Execution Time Calculation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
long start = System.nanoTime(); | |
// do work..... | |
long time = System.nanoTime() - start; | |
double timeInSeconds = time/1e9; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment