Last active
November 12, 2015 15:20
-
-
Save brschwar/93a2f7e4b383bf841ee0 to your computer and use it in GitHub Desktop.
"Timer" Feature to Optimize Your Code: Determine how long an operation takes by using "timer" feature to log the results.
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
function TimeTracker(){ | |
console.time("MyTimer"); | |
for(x=5000; x > 0; x--){} | |
console.timeEnd("MyTimer"); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment