<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def setdefault(obj, field, default):
 """Set an object's field to default if it doesn't have a value"""

    setattr(obj, field, getattr(obj, field, default))