Question: Which county of Maryland borders Howard County (subreddit Hoco) and also borders Harford County ?
Choices:
Montgomery County
Frederick County
Harford County
Carroll County
Allegany County
Charles County
Howard County
Cecil County
Baltimore County
Kent County
Answer: Baltimore County
SPARQL: SELECT DISTINCT ?e WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "county of Maryland" . ?e_1 <shares_border_with> ?e . ?e_1 <pred:name> "Howard County" . ?e_1 <subreddit> ?pv . ?pv <pred:value> "Hoco" .  ?e <shares_border_with> ?e_2 . ?e_2 <pred:name> "Harford County" .  }
Program:
function: Find
inputs: Howard County
function: FilterStr
dependencies: 0
inputs: subreddit
Hoco
function: Relate
dependencies: 1
inputs: shares border with
forward
function: FilterConcept
dependencies: 2
inputs: county of Maryland
function: Find
inputs: Harford County
function: Relate
dependencies: 4
inputs: shares border with
backward
function: FilterConcept
dependencies: 5
inputs: county of Maryland
function: And
dependencies: 3
6
function: What
dependencies: 7