<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def list_functions(region=None, key=None, keyid=None, profile=None):
    '''
    List all Lambda functions visible in the current scope.

    CLI Example:

    .. code-block:: bash

        salt myminion boto_lambda.list_functions

    '''
    conn = _get_conn(region=region, key=key, keyid=keyid, profile=profile)

    ret = []
    for funcs in __utils__['boto3.paged_call'](conn.list_functions):
        ret += funcs['Functions']
    return ret