I'm not even sure what problems I may encounter using this, but I just love being able to do this in the first place:
PYTHON:
>>> def time_func(func, *args):
... from time import time
... t = time()
... results = func(*args)
... return (time()-t, results)
...
>>> def something(line, line2):
... for i in range(10000000):
... [...]