<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 (self, key, def_val=None):
 """Update key usage if found and return value, else set and return default."""

        if key in self:
            return self[key]
        self[key] = def_val
        return def_val