Question: Which one of these has fewer kids, Frank Marshall (the one that is produced The Color Purple) or Jeremy Clarkson ?
Choices:
Max Fleischer
David Byrne
Simon Cowell
Frank Marshall
Paul Simon
Rahul Dev Burman
Jeremy Clarkson
Richard Gere
Sylvester Stallone
William Henry Harrison
Program:
function: Find
inputs: The Color Purple
function: Relate
dependencies: 0
inputs: producer
forward
function: Find
inputs: Frank Marshall
function: And
dependencies: 1
2
function: Find
inputs: Jeremy Clarkson
function: SelectBetween
dependencies: 3
4
inputs: number of children
less
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Frank Marshall" . ?e_1 <producer> ?e . ?e_1 <pred:name> "The Color Purple" .   } UNION { ?e <pred:name> "Jeremy Clarkson" .  } ?e <number_of_children> ?pv . ?pv <pred:value> ?v .  } ORDER BY ?v LIMIT 1
Answer: Frank Marshall