Question: How many historical country use Portuguese as the official language or whose population is not equal to 9.0?
Choices:
11
12
13
14
15
16
17
18
19
20
Program:
function: Find
inputs: Portuguese
function: Relate
dependencies: 0
inputs: official language
backward
function: FilterConcept
dependencies: 1
inputs: historical country
function: FindAll
function: FilterNum
dependencies: 3
inputs: population
9.0
!=
function: FilterConcept
dependencies: 4
inputs: historical country
function: Or
dependencies: 2
5
function: Count
dependencies: 6
SPARQL: SELECT (COUNT(DISTINCT ?e) AS ?count) WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "historical country" .  { ?e <official_language> ?e_1 . ?e_1 <pred:name> "Portuguese" .  } UNION { ?e <population> ?pv . ?pv <pred:unit> "1" . ?pv <pred:value> ?v . FILTER ( ?v != "9.0"^^xsd:double ) .  } }
Answer: 11