Question: Which has the higher male population, Haryana, which uses Hindi as the official language, or Karnataka?
Choices:
Odisha
Kerala
Gujarat
Karnataka
Haryana
Punjab
Maharashtra
Himachal Pradesh
West Bengal
Jharkhand
Answer: Karnataka
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Haryana" . ?e <official_language> ?e_1 . ?e_1 <pred:name> "Hindi" .   } UNION { ?e <pred:name> "Karnataka" .  } ?e <male_population> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Program:
function: Find
inputs: Hindi
function: Relate
dependencies: 0
inputs: official language
backward
function: Find
inputs: Haryana
function: And
dependencies: 1
2
function: Find
inputs: Karnataka
function: SelectBetween
dependencies: 3
4
inputs: male population
greater