Question: How many high schools are located either in Manhatan, which has a 212 area code, or the Bronx?
Choices:
3
4
5
6
7
8
9
10
11
12
Answer: 3
SPARQL: SELECT (COUNT(DISTINCT ?e) AS ?count) WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "high school" .  { ?e <located_in_the_administrative_territorial_entity> ?e_1 . ?e_1 <pred:name> "Manhattan" . ?e_1 <local_dialing_code> ?pv . ?pv <pred:value> "212" .  } UNION { ?e <located_in_the_administrative_territorial_entity> ?e_1 . ?e_1 <pred:name> "The Bronx" .  } }
Program:
function: Find
inputs: Manhattan
function: FilterStr
dependencies: 0
inputs: local dialing code
212
function: Relate
dependencies: 1
inputs: located in the administrative territorial entity
backward
function: FilterConcept
dependencies: 2
inputs: high school
function: Find
inputs: The Bronx
function: Relate
dependencies: 4
inputs: located in the administrative territorial entity
backward
function: FilterConcept
dependencies: 5
inputs: high school
function: Or
dependencies: 3
6
function: Count
dependencies: 7