Question: Is the episode count higher for Rules of Engagement, produced by Happy Madison Productions, or The Shield?
Choices:
Phineas and Ferb
American Horror Story
Game of Thrones
Robot Chicken
The Shield
Six Feet Under
Bleak House
Rules of Engagement
Dancing with the Stars
Saturday Night's Main Event
Program:
function: Find
inputs: Happy Madison Productions
function: Relate
dependencies: 0
inputs: production company
backward
function: Find
inputs: Rules of Engagement
function: And
dependencies: 1
2
function: Find
inputs: The Shield
function: SelectBetween
dependencies: 3
4
inputs: number of episodes
greater
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Rules of Engagement" . ?e <production_company> ?e_1 . ?e_1 <pred:name> "Happy Madison Productions" .   } UNION { ?e <pred:name> "The Shield" .  } ?e <number_of_episodes> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Answer: Rules of Engagement