from typing import Any
from typing import Tuple


def exec_command(node, **kwargs: Any) -> Tuple:
    """
    Return the results of the command executed.

    Args:
        node:   The node to be used for executing the given command.
        kwargs: The supported keys are
                sudo    - Default false, root privilege to be used or not
                cmd     - The command to be executed
                check_ec - Evaluate the error code returned.

    Return:
        out, err    String values

    Raises:
        CommandFailed   when there is an execution failure
    """
    out, err = node.exec_command(**kwargs)
    return out, err