<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def reverse(d):
 """Return a reverse lookup dictionary for the input dictionary"""

    r={}
    for k in d:
        r[d[k]]=k
    return r