Created
October 9, 2017 18:53
-
-
Save mizushou/25d1cae145f5e2a61e28f1c7c3980e44 to your computer and use it in GitHub Desktop.
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
class TimeMeasurement { | |
public static void main(String[] args) { | |
long start = System.nanoTime(); | |
// some processing | |
int[] a = {1,2,3,4,4,5,6,7,8,9,10}; | |
for(int i=0; i<a.length; i++){ | |
System.out.println(a[i]); | |
}; | |
long end = System.nanoTime(); | |
System.out.println("Time : " + (end - start) / 1000000f + "ms"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
処理時間計測