from typing import Callable
import time


def timeit(func: Callable) -> Callable:
    """A decorator for functions, add execution time of a function as an additional return value.

    Use as @timeit just above your function definition.

    Args:
        func: A callable, could be any function.

    Returns:
        A wrapped function (callable) with one additional return value.
        Execution time (number of seconds) (int) is returned as the first return
        value. Any return values of the origial function is returned as the
        second value.

    Raises:
        None
    """

    def wrapped_function(*args, **kwargs):
        start_time = time.time()
        result = func(*args, **kwargs)
        elapsed: float = time.time() - start_time
        return elapsed, result

    return wrapped_function