Added decorator for timing functions.

Use it by @timeit

fixes #7