Question: How many 3D movies clock in at other than 660 minutes or are part of The Smurfs, with George Lopez as a cast member?
Choices:
0
1
2
3
4
5
6
7
8
9
Answer: 5
SPARQL: SELECT (COUNT(DISTINCT ?e) AS ?count) WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "3D film" .  { ?e <duration> ?pv . ?pv <pred:unit> "minute" . ?pv <pred:value> ?v . FILTER ( ?v != "660"^^xsd:double ) .  } UNION { ?e <part_of_the_series> ?e_1 . ?e_1 <pred:name> "The Smurfs" . ?e_1 <cast_member> ?e_2 . ?e_2 <pred:name> "George Lopez" .  } }
Program:
function: FindAll
function: FilterNum
dependencies: 0
inputs: duration
660 minute
!=
function: FilterConcept
dependencies: 1
inputs: 3D film
function: Find
inputs: George Lopez
function: Relate
dependencies: 3
inputs: cast member
backward
function: Find
inputs: The Smurfs
function: And
dependencies: 4
5
function: Relate
dependencies: 6
inputs: part of the series
backward
function: FilterConcept
dependencies: 7
inputs: 3D film
function: Or
dependencies: 2
8
function: Count
dependencies: 9