Question: Does the Washington County that borders Beaver County or the Wayne County that borders Lackawanna County occupy a smaller area?
Choices:
Washington County
Fayette County
Franklin County
Allegheny County
Westmoreland County
York County
Wayne County
Warren County
Bucks County
Lehigh County
Answer: Wayne County
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Washington County" . ?e <shares_border_with> ?e_1 . ?e_1 <pred:name> "Beaver County" .   } UNION { ?e <pred:name> "Wayne County" . ?e <shares_border_with> ?e_2 . ?e_2 <pred:name> "Lackawanna County" .  } ?e <area> ?pv . ?pv <pred:value> ?v .  } ORDER BY ?v LIMIT 1
Program:
function: Find
inputs: Beaver County
function: Relate
dependencies: 0
inputs: shares border with
backward
function: Find
inputs: Washington County
function: And
dependencies: 1
2
function: Find
inputs: Lackawanna County
function: Relate
dependencies: 4
inputs: shares border with
backward
function: Find
inputs: Wayne County
function: And
dependencies: 5
6
function: SelectBetween
dependencies: 3
7
inputs: area
less