Question: How many counties of Maine contains the administrative division of the city of the United States that is the origin of the name Portland (the one that is the twinned administrative body of Sapporo)?
Choices:
0
1
2
3
4
5
6
7
8
9
Answer: 1
SPARQL: SELECT (COUNT(DISTINCT ?e) AS ?count) WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "county of Maine" . ?e <contains_administrative_territorial_entity> ?e_1 . ?e_1 <pred:instance_of> ?c_1 . ?c_1 <pred:name> "city of the United States" . ?e_3 <named_after> ?e_1 . ?e_3 <pred:name> "Portland" . ?e_4 <twinned_administrative_body> ?e_3 . ?e_4 <pred:name> "Sapporo" .   }
Program:
function: Find
inputs: Sapporo
function: Relate
dependencies: 0
inputs: twinned administrative body
forward
function: Find
inputs: Portland
function: And
dependencies: 1
2
function: Relate
dependencies: 3
inputs: named after
forward
function: FilterConcept
dependencies: 4
inputs: city of the United States
function: Relate
dependencies: 5
inputs: contains administrative territorial entity
backward
function: FilterConcept
dependencies: 6
inputs: county of Maine
function: Count
dependencies: 7