-
-
Save jianghu52/377cd24febe2c2fda97c 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
import datetime | |
def timeit(func): | |
def warp(*args): | |
print "begin at " + str(datetime.datetime.now()) | |
func(*args) | |
print "end at " + str(datetime.datetime.now()) | |
return warp | |
@timeit | |
def foo2(*args): | |
print "function run" | |
foo2() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment