<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def lock(account_id, resource_id, region):
 """Lock a resource """

    return output(
        Client(BASE_URL, account_id).lock(resource_id, region))