Question: What is the connection between Middlesex County (the one that shares border with Norfolk County) to Suffolk County (the one that contains the administrative division Boston)?
Choices:
territory overlaps
military branch
office held by head of state
sibling
position held
stated in
official symbol
winner
shares border with
soundtrack album
Program:
function: Find
inputs: Norfolk County
function: Relate
dependencies: 0
inputs: shares border with
backward
function: Find
inputs: Middlesex County
function: And
dependencies: 1
2
function: Find
inputs: Boston
function: Relate
dependencies: 4
inputs: contains administrative territorial entity
backward
function: Find
inputs: Suffolk County
function: And
dependencies: 5
6
function: QueryRelation
dependencies: 3
7
SPARQL: SELECT DISTINCT ?p WHERE { ?e_1 <pred:name> "Middlesex County" . ?e_1 <shares_border_with> ?e_3 . ?e_3 <pred:name> "Norfolk County" . ?e_2 <pred:name> "Suffolk County" . ?e_2 <contains_administrative_territorial_entity> ?e_4 . ?e_4 <pred:name> "Boston" . ?e_1 ?p ?e_2 .  }
Answer: shares border with