<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def share_with_names(self):
 """The names of the containers that we share with the running container"""

        for container in self.share_with:
            if isinstance(container, six.string_types):
                yield container
            else:
                yield container.container_name