<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def execute(self, command=None, container_id=None, sudo=False, stream=False):
    '''execute a command to a container instance based on container_id

       Parameters
       ==========
       container_id: the container_id to delete
       command: the command to execute to the container
       sudo: whether to issue the command with sudo (or not)
             a container started with sudo will belong to the root user
             If started by a user, the user needs to control deleting it
       stream: if True, return an iterate to iterate over results of exec.
               default is False, will return full output as string.

       Returns
       =======
       return_code: the return code from the delete command. 0 indicates a
                    successful delete, 255 indicates not.
    '''
    sudo = self._get_sudo(sudo)
    container_id = self.get_container_id(container_id)

    # singularity oci delete
    cmd = self._init_command('exec')

    # Add the container_id
    cmd.append(container_id)

    if command != None:
        if not isinstance(command, list):
            command = [command]

        cmd = cmd + command

        # Execute the command, return response to user
        if stream:
            return stream_command(cmd, sudo=sudo)
        return self._run_command(cmd, sudo=sudo, quiet=True)