Question: Which has a greater area, Hampshire (whose official website is http://www.hants.gov.uk) or Buckinghamshire?
Choices:
Essex
Norfolk
Northumberland
Hampshire
Cumbria
Staffordshire
Warwickshire
Buckinghamshire
West Midlands
Somerset
Program:
function: Find
inputs: Hampshire
function: FilterStr
dependencies: 0
inputs: official website
http://www.hants.gov.uk
function: Find
inputs: Buckinghamshire
function: SelectBetween
dependencies: 1
2
inputs: area
greater
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Hampshire" . ?e <official_website> ?pv_1 . ?pv_1 <pred:value> "http://www.hants.gov.uk" . } UNION { ?e <pred:name> "Buckinghamshire" . } ?e <area> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Answer: Hampshire