Question: How many Indian states are designated by ISO 3166-2 code IN-AS or have other than 27,000 female inhabitants?
Choices:
18
19
20
21
22
23
24
25
26
27
Answer: 23
SPARQL: SELECT (COUNT(DISTINCT ?e) AS ?count) WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "state of India" .  { ?e <ISO_3166-2_code> ?pv . ?pv <pred:value> "IN-AS" .  } UNION { ?e <female_population> ?pv . ?pv <pred:unit> "1" . ?pv <pred:value> ?v . FILTER ( ?v != "27000"^^xsd:double ) .  } }
Program:
function: FindAll
function: FilterStr
dependencies: 0
inputs: ISO 3166-2 code
IN-AS
function: FilterConcept
dependencies: 1
inputs: state of India
function: FindAll
function: FilterNum
dependencies: 3
inputs: female population
27000
!=
function: FilterConcept
dependencies: 4
inputs: state of India
function: Or
dependencies: 2
5
function: Count
dependencies: 6