From dd4896a1fcf763d2b7d0ca930c2fdc167f70f571 Mon Sep 17 00:00:00 2001 From: Matthew Ellison Date: Fri, 25 Jan 2019 01:07:44 -0500 Subject: [PATCH] Removed unnecessary code and added results section --- testStopwatch.py | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/testStopwatch.py b/testStopwatch.py index 361fb40..9240c9e 100644 --- a/testStopwatch.py +++ b/testStopwatch.py @@ -23,7 +23,6 @@ cnt = 0 #A loop just to eat up time print("\n\nEntering loop") while(cnt < 10000): - #print(cnt) cnt = cnt + 1 print("Exiting loop\n") timer.stop() @@ -44,5 +43,28 @@ print(str(timer.getNanoseconds()) + " nanoseconds") print("\nEND OF TEST") """Results: +BEGIN TEST +Trying to print the time before it has been started: +-1 +Trying to print the time after stop was called, but before start was: +-1 +Trying to print the time after it was started but before it was stopped: +654000 + + +Entering loop +Exiting loop + +Trying to print time after it was finished: +5426600 + + +Print times in specific resolutions: +0.005427 seconds +5.4266 milliseconds +5426.6 microseconds +5426600 nanoseconds + +END OF TEST """