Question: How many astronomical-object types have a model item Earth (the one that is a model item planet) or have nebula as a part?
Choices: 0
1
2
3
4
5
6
7
8
9
SPARQL: SELECT (COUNT(DISTINCT ?e) AS ?count) WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "astronomical object type" .  { ?e <model_item> ?e_1 . ?e_1 <pred:name> "Earth" . ?e_2 <model_item> ?e_1 . ?e_2 <pred:name> "planet" .  } UNION { ?e_1 <part_of> ?e . ?e_1 <pred:name> "nebula" .  } }
Program:
function: Find
inputs: planet
function: Relate
dependencies: 0
inputs: model item
forward
function: Find
inputs: Earth
function: And
dependencies: 1
2
function: Relate
dependencies: 3
inputs: model item
backward
function: FilterConcept
dependencies: 4
inputs: astronomical object type
function: Find
inputs: nebula
function: Relate
dependencies: 6
inputs: part of
forward
function: FilterConcept
dependencies: 7
inputs: astronomical object type
function: Or
dependencies: 5
8
function: Count
dependencies: 9
Answer: 2