Question: Which island is different from Cuba that has a diplomatic relation with United Kingdom?
Choices:
Iceland
Cuba
Ireland
Newfoundland
Trinidad
Honshu
Tasmania
Puerto Rico
Hawaii
North Island
Program:
function: Find
inputs: United Kingdom
function: Relate
dependencies: 0
inputs: diplomatic relation
backward
function: Find
inputs: Cuba
function: And
dependencies: 1
2
function: Relate
dependencies: 3
inputs: different from
backward
function: FilterConcept
dependencies: 4
inputs: island
function: What
dependencies: 5
SPARQL: SELECT DISTINCT ?e WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "island" . ?e <different_from> ?e_1 . ?e_1 <pred:name> "Cuba" . ?e_1 <diplomatic_relation> ?e_2 . ?e_2 <pred:name> "United Kingdom" .   }
Answer: Cuba