Question: For the U.S. state that is Americana's (producer is David Carradine) filming location, how many public offices head its government?
Choices: 0
1
2
3
4
5
6
7
8
9
SPARQL: SELECT (COUNT(DISTINCT ?e) AS ?count) WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "public office" . ?e_1 <office_held_by_head_of_government> ?e . ?e_1 <pred:instance_of> ?c_1 . ?c_1 <pred:name> "state of the United States" . ?e_2 <filming_location> ?e_1 . ?e_2 <pred:name> "Americana" . ?e_2 <producer> ?e_3 . ?e_3 <pred:name> "David Carradine" .   }
Program:
function: Find
inputs: David Carradine
function: Relate
dependencies: 0
inputs: producer
backward
function: Find
inputs: Americana
function: And
dependencies: 1
2
function: Relate
dependencies: 3
inputs: filming location
forward
function: FilterConcept
dependencies: 4
inputs: state of the United States
function: Relate
dependencies: 5
inputs: office held by head of government
forward
function: FilterConcept
dependencies: 6
inputs: public office
function: Count
dependencies: 7
Answer: 1