code: def timing(func):
      
      @functools.wraps(func)
      def wrap(*args, **kw):
          t0 = time()
          result = func(*args, **kw)
          t1 = time()
          print('func:%r args:[%r, %r] took: %2.4f sec' %
                (func.__name__, args, kw, t1 - t0))
          return result
      return wrap
docs: Measure the execution time of a function call and print the result.