Question: Which show has fewer episodes, Fresno (the one that has Carol Burnett as a cast member) or The Adventures of Tintin (the one that origins from Canada)?
Choices:
Fresno
Battlestar Galactica
Roots
The Civil War
The Ten Commandments
The Stand
The Pacific
The Diary of Anne Frank
The Adventures of Tintin
Edge of Darkness
Program:
function: Find
inputs: Carol Burnett
function: Relate
dependencies: 0
inputs: cast member
backward
function: Find
inputs: Fresno
function: And
dependencies: 1
2
function: Find
inputs: Canada
function: Relate
dependencies: 4
inputs: country of origin
backward
function: Find
inputs: The Adventures of Tintin
function: And
dependencies: 5
6
function: SelectBetween
dependencies: 3
7
inputs: number of episodes
less
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Fresno" . ?e <cast_member> ?e_1 . ?e_1 <pred:name> "Carol Burnett" .   } UNION { ?e <pred:name> "The Adventures of Tintin" . ?e <country_of_origin> ?e_2 . ?e_2 <pred:name> "Canada" .  } ?e <number_of_episodes> ?pv . ?pv <pred:value> ?v .  } ORDER BY ?v LIMIT 1
Answer: Fresno