If the dog in the image on the right is wearing a hat with a black band around the crown.
return right image ;return dog of #1 ;return hat ;return crown of hat ;return band ;return #5 that is black ;return #3 where  #4 has #6 ;return if  #2 is wearing #7
['select', 'project', 'select', 'select', 'select', 'filter', 'comparative', 'boolean']