Question: Does Hannibal (that has 39 episodes) or Collateral (that has Carey Mulligan as a cast member) have more episodes?
Choices:
Phineas and Ferb
Dancing with the Stars
Saturday Night's Main Event
American Horror Story
Bleak House
Seinfeld
Six Feet Under
Hannibal
Robot Chicken
Collateral
Answer: Hannibal
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Hannibal" . ?e <number_of_episodes> ?pv_1 . ?pv_1 <pred:unit> "1" . ?pv_1 <pred:value> "39"^^xsd:double . } UNION { ?e <pred:name> "Collateral" . ?e <cast_member> ?e_1 . ?e_1 <pred:name> "Carey Mulligan" . } ?e <number_of_episodes> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Program:
function: Find
inputs: Hannibal
function: FilterNum
dependencies: 0
inputs: number of episodes
39
=
function: Find
inputs: Carey Mulligan
function: Relate
dependencies: 2
inputs: cast member
backward
function: Find
inputs: Collateral
function: And
dependencies: 3
4
function: SelectBetween
dependencies: 1
5
inputs: number of episodes
greater