<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def fork(self, command: Command) \ -> Tuple['SelectedMailbox', Iterable[Response]]: """Compares the state of the current object to that of the last fork, returning the untagged responses that reflect any changes. A new copy of the object is also returned, ready for the next command. Args: command: The command that was finished. """

        frozen = _Frozen(self)
        cls = type(self)
        copy = cls(self._guid, self._readonly, self._permanent_flags,
                   self._session_flags, self._selected_set, self._lookup,
                   _mod_sequence=self._mod_sequence,
                   _prev=frozen, _messages=self._messages)
        if self._prev is not None:
            with_uid: bool = getattr(command, 'uid', False)
            untagged = self._compare(self._prev, frozen, with_uid)
        else:
            untagged = []
        return copy, untagged