Question: Which movie is longer, P.S. I Love You (the one that origins from United States of America) or Cloud Atlas (the one whose release region is South Korea)?
Choices:
Cloud Atlas
The Towering Inferno
The Hunchback of Notre Dame
Rebecca
A Prairie Home Companion
Training Day
Pleasantville
Curse of the Golden Flower
The Fifth Element
Talk to Her
Program:
function: Find
inputs: United States of America
function: Relate
dependencies: 0
inputs: country of origin
backward
function: Find
inputs: P.S. I Love You
function: And
dependencies: 1
2
function: Find
inputs: South Korea
function: Relate
dependencies: 4
inputs: film release region
backward
function: Find
inputs: Cloud Atlas
function: And
dependencies: 5
6
function: SelectBetween
dependencies: 3
7
inputs: duration
greater
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "P.S. I Love You" . ?e <country_of_origin> ?e_1 . ?e_1 <pred:name> "United States of America" .   } UNION { ?e <pred:name> "Cloud Atlas" . ?e <film_release_region> ?e_2 . ?e_2 <pred:name> "South Korea" .  } ?e <duration> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Answer: Cloud Atlas