Question: How many visual artworks derive The World Is Not Enough (whose narrative location is Spain) or are the origin of the name Black Sabbath (which received Rock and Roll Hall of Fame)?
Choices:
1
2
3
4
5
6
7
8
9
10
Answer: 2
SPARQL: SELECT (COUNT(DISTINCT ?e) AS ?count) WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "visual artwork" .  { ?e_1 <based_on> ?e . ?e_1 <pred:name> "The World Is Not Enough" . ?e_1 <narrative_location> ?e_2 . ?e_2 <pred:name> "Spain" .  } UNION { ?e_1 <named_after> ?e . ?e_1 <pred:name> "Black Sabbath" . ?e_1 <award_received> ?e_2 . ?e_2 <pred:name> "Rock and Roll Hall of Fame" .  } }
Program:
function: Find
inputs: Spain
function: Relate
dependencies: 0
inputs: narrative location
backward
function: Find
inputs: The World Is Not Enough
function: And
dependencies: 1
2
function: Relate
dependencies: 3
inputs: based on
forward
function: FilterConcept
dependencies: 4
inputs: visual artwork
function: Find
inputs: Rock and Roll Hall of Fame
function: Relate
dependencies: 6
inputs: award received
backward
function: Find
inputs: Black Sabbath
function: And
dependencies: 7
8
function: Relate
dependencies: 9
inputs: named after
forward
function: FilterConcept
dependencies: 10
inputs: visual artwork
function: Or
dependencies: 5
11
function: Count
dependencies: 12