<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def setex(self, name, time, value):
 """ Set the value of ``name`` to ``value`` that expires in ``time`` seconds. ``time`` can be represented by an integer or a Python timedelta object. """

        if not self.strict:
            # when not strict mode swap value and time args order
            time, value = value, time
        return self.set(name, value, ex=time)