Question: Who was nominated for an Academy Award for Best Actor for Richard III (which has Ralph Richardson as a cast member)?
Choices:
Brenda Blethyn
Fredric M. Frank
Kevin Tent
Freddie Francis
Laurence Olivier
Joel Hynek
Denholm Elliott
Will Rokos
Gordon Sim
Denis Héroux
Answer: Laurence Olivier
SPARQL: SELECT DISTINCT ?qpv WHERE { ?e_1 <pred:name> "Richard III" . ?e_1 <cast_member> ?e_3 . ?e_3 <pred:name> "Ralph Richardson" . ?e_2 <pred:name> "Academy Award for Best Actor" . ?e_1 <nominated_for> ?e_2 . [ <pred:fact_h> ?e_1 ; <pred:fact_r> <nominated_for> ; <pred:fact_t> ?e_2 ] <nominee> ?qpv .  }
Program:
function: Find
inputs: Ralph Richardson
function: Relate
dependencies: 0
inputs: cast member
backward
function: Find
inputs: Richard III
function: And
dependencies: 1
2
function: Find
inputs: Academy Award for Best Actor
function: QueryRelationQualifier
dependencies: 3
4
inputs: nominated for
nominee