Question: Which is longer, The Kingdom with Jeremy Piven in the cast or Take Shelter with LisaGay Hamilton in the cast?
Choices:
The Towering Inferno
The Fifth Element
Curse of the Golden Flower
The Hunchback of Notre Dame
Training Day
Talk to Her
A Prairie Home Companion
Pleasantville
Rebecca
Take Shelter
Answer: Take Shelter
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "The Kingdom" . ?e <cast_member> ?e_1 . ?e_1 <pred:name> "Jeremy Piven" .   } UNION { ?e <pred:name> "Take Shelter" . ?e <cast_member> ?e_2 . ?e_2 <pred:name> "LisaGay Hamilton" .  } ?e <duration> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Program:
function: Find
inputs: Jeremy Piven
function: Relate
dependencies: 0
inputs: cast member
backward
function: Find
inputs: The Kingdom
function: And
dependencies: 1
2
function: Find
inputs: LisaGay Hamilton
function: Relate
dependencies: 4
inputs: cast member
backward
function: Find
inputs: Take Shelter
function: And
dependencies: 5
6
function: SelectBetween
dependencies: 3
7
inputs: duration
greater