Question: Which area is larger, Durham (the one whose population is 5485) or Hagerstown?
Choices:
Waukegan
Boulder
Columbus
Oakland
Durham
Hagerstown
Franklin
Lansing
New Haven
Compton
Program:
function: Find
inputs: Durham
function: FilterNum
dependencies: 0
inputs: population
5485
=
function: Find
inputs: Hagerstown
function: SelectBetween
dependencies: 1
2
inputs: area
greater
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Durham" . ?e <population> ?pv_1 . ?pv_1 <pred:unit> "1" . ?pv_1 <pred:value> "5485"^^xsd:double . } UNION { ?e <pred:name> "Hagerstown" . } ?e <area> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Answer: Durham