else/Templates/timetest.py
Ethan Dalool 0896ba96e6 else
2016-12-22 19:42:21 -08:00

22 lines
276 B
Python

import time
LOOPS = 10000
def func_1():
pass
def func_2():
pass
start = time.time()
for x in range(LOOPS):
func_1()
end = time.time()
print('v1', end - start)
start = time.time()
for x in range(LOOPS):
func_2()
end = time.time()
print('v2', end - start)