Question: what country does it belong to for James Bond (who died of cancer) died in Philadelphia (which is the headquarter location of American philosophical Society).
Choices:
Germany
France
United States of America
Lebanon
Austria-Hungary
Canada
Russian Soviet Federative Socialist Republic
international
Singapore
South Korea
Program:
function: Find
inputs: cancer
function: Relate
dependencies: 0
inputs: cause of death
backward
function: Find
inputs: James Bond
function: And
dependencies: 1
2
function: Find
inputs: American Philosophical Society
function: Relate
dependencies: 4
inputs: headquarters location
forward
function: Find
inputs: Philadelphia
function: And
dependencies: 5
6
function: QueryRelationQualifier
dependencies: 3
7
inputs: place of death
country
SPARQL: SELECT DISTINCT ?qpv WHERE { ?e_1 <pred:name> "James Bond" . ?e_1 <cause_of_death> ?e_3 . ?e_3 <pred:name> "cancer" . ?e_2 <pred:name> "Philadelphia" . ?e_4 <headquarters_location> ?e_2 . ?e_4 <pred:name> "American Philosophical Society" . ?e_1 <place_of_death> ?e_2 . [ <pred:fact_h> ?e_1 ; <pred:fact_r> <place_of_death> ; <pred:fact_t> ?e_2 ] <country> ?qpv .  }
Answer: United States of America