Question: Which movie is longer, Luther (the one whose publication date is 1964) or The Producers (the one that has Will Ferrell as a cast member)?
Choices:
The Producers
Luther
A Prairie Home Companion
Curse of the Golden Flower
Pleasantville
The Hunchback of Notre Dame
Rebecca
The Towering Inferno
Talk to Her
The Fifth Element
Program:
function: Find
inputs: Luther
function: FilterYear
dependencies: 0
inputs: publication date
1964
=
function: Find
inputs: Will Ferrell
function: Relate
dependencies: 2
inputs: cast member
backward
function: Find
inputs: The Producers
function: And
dependencies: 3
4
function: SelectBetween
dependencies: 1
5
inputs: duration
greater
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Luther" . ?e <publication_date> ?pv_1 . ?pv_1 <pred:year> 1964 . } UNION { ?e <pred:name> "The Producers" . ?e <cast_member> ?e_1 . ?e_1 <pred:name> "Will Ferrell" . } ?e <duration> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Answer: The Producers