Question: What is the relationship between Somerville (the one whose local dialing code is 617) and Middlesex County (the one that shares border with Norfolk County)?
Choices:
named after
symptoms
has contributing factor
dissertation submitted to
located in the administrative territorial entity
candidacy in election
relative
notable people with this condition
official religion
home venue
Answer: located in the administrative territorial entity
SPARQL: SELECT DISTINCT ?p WHERE { ?e_1 <pred:name> "Somerville" . ?e_1 <local_dialing_code> ?pv . ?pv <pred:value> "617" . ?e_2 <pred:name> "Middlesex County" . ?e_3 <shares_border_with> ?e_2 . ?e_3 <pred:name> "Norfolk County" . ?e_1 ?p ?e_2 .  }
Program:
function: Find
inputs: Somerville
function: FilterStr
dependencies: 0
inputs: local dialing code
617
function: Find
inputs: Norfolk County
function: Relate
dependencies: 2
inputs: shares border with
forward
function: Find
inputs: Middlesex County
function: And
dependencies: 3
4
function: QueryRelation
dependencies: 1
5