Question: Which place—Suffolk County (with a capital of Boston) or Berkshire County—has a larger area?
Choices:
Berkshire County
Essex County
Hampshire County
Plymouth County
Suffolk County
Worcester County
Norfolk County
Middlesex County
Barnstable County
Franklin County
Program:
function: Find
inputs: Boston
function: Relate
dependencies: 0
inputs: capital of
forward
function: Find
inputs: Suffolk County
function: And
dependencies: 1
2
function: Find
inputs: Berkshire County
function: SelectBetween
dependencies: 3
4
inputs: area
greater
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Suffolk County" . ?e_1 <capital_of> ?e . ?e_1 <pred:name> "Boston" .   } UNION { ?e <pred:name> "Berkshire County" .  } ?e <area> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Answer: Berkshire County