Question: Which area is smaller, Klamath County or Jackson County (the one that shares border with Klamath County)?
Choices:
Klamath County
Jackson County
Columbia County
Douglas County
Washington County
Lake County
Clackamas County
Linn County
Tillamook County
Yamhill County
Program:
function: Find
inputs: Klamath County
function: Find
inputs: Klamath County
function: Relate
dependencies: 1
inputs: shares border with
backward
function: Find
inputs: Jackson County
function: And
dependencies: 2
3
function: SelectBetween
dependencies: 0
4
inputs: area
less
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Klamath County" .  } UNION { ?e <pred:name> "Jackson County" . ?e <shares_border_with> ?e_1 . ?e_1 <pred:name> "Klamath County" .   } ?e <area> ?pv . ?pv <pred:value> ?v .  } ORDER BY ?v LIMIT 1
Answer: Jackson County