Question: Which movie is longer, The Rocketeer (the one that has Jennifer Connelly as a cast member) or Alice in Wonderland (the one that was nominated for MTV Movie Award for Best Villain)?
Choices:
The Flintstones
National Treasure: Book of Secrets
The Muppets
The Rocketeer
Alice in Wonderland
G-Force
The Flintstones in Viva Rock Vegas
John Carter
Old Dogs
Holes
Answer: Alice in Wonderland
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "The Rocketeer" . ?e <cast_member> ?e_1 . ?e_1 <pred:name> "Jennifer Connelly" .   } UNION { ?e <pred:name> "Alice in Wonderland" . ?e <nominated_for> ?e_2 . ?e_2 <pred:name> "MTV Movie Award for Best Villain" .  } ?e <duration> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Program:
function: Find
inputs: Jennifer Connelly
function: Relate
dependencies: 0
inputs: cast member
backward
function: Find
inputs: The Rocketeer
function: And
dependencies: 1
2
function: Find
inputs: MTV Movie Award for Best Villain
function: Relate
dependencies: 4
inputs: nominated for
backward
function: Find
inputs: Alice in Wonderland
function: And
dependencies: 5
6
function: SelectBetween
dependencies: 3
7
inputs: duration
greater