Question: Which has greater net worth, Bradley Cooper who is an executive producer of Silver Linings Playbook or David Letterman?
Choices:
Paul Simon
Sylvester Stallone
Max Fleischer
James E. Reilly
David Letterman
Bradley Cooper
Richard Gere
William Henry Harrison
Rahul Dev Burman
David Byrne
Program:
function: Find
inputs: Silver Linings Playbook
function: Relate
dependencies: 0
inputs: executive producer
forward
function: Find
inputs: Bradley Cooper
function: And
dependencies: 1
2
function: Find
inputs: David Letterman
function: SelectBetween
dependencies: 3
4
inputs: net worth
greater
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Bradley Cooper" . ?e_1 <executive_producer> ?e . ?e_1 <pred:name> "Silver Linings Playbook" .   } UNION { ?e <pred:name> "David Letterman" .  } ?e <net_worth> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Answer: David Letterman