Question: Which is longer, Masada or Luther produced by the BBC?
Choices:
The Stand
The Civil War
Edge of Darkness
George Washington
Luther
Battlestar Galactica
The Diary of Anne Frank
The Pacific
The Ten Commandments
Masada
Program:
function: Find
inputs: Masada
function: Find
inputs: BBC
function: Relate
dependencies: 1
inputs: production company
backward
function: Find
inputs: Luther
function: And
dependencies: 2
3
function: SelectBetween
dependencies: 0
4
inputs: duration
greater
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Masada" .  } UNION { ?e <pred:name> "Luther" . ?e <production_company> ?e_1 . ?e_1 <pred:name> "BBC" .   } ?e <duration> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Answer: Masada