Question: How many Indian states have over 780000000 rural dwellers or border Bihar?
Choices:
3
4
5
6
7
8
9
10
11
12
Answer: 3
SPARQL: SELECT (COUNT(DISTINCT ?e) AS ?count) WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "state of India" .  { ?e <rural_population> ?pv . ?pv <pred:unit> "1" . ?pv <pred:value> ?v . FILTER ( ?v > "780000000"^^xsd:double ) .  } UNION { ?e <shares_border_with> ?e_1 . ?e_1 <pred:name> "Bihar" .  } }
Program:
function: FindAll
function: FilterNum
dependencies: 0
inputs: rural population
780000000
>
function: FilterConcept
dependencies: 1
inputs: state of India
function: Find
inputs: Bihar
function: Relate
dependencies: 3
inputs: shares border with
backward
function: FilterConcept
dependencies: 4
inputs: state of India
function: Or
dependencies: 2
5
function: Count
dependencies: 6