Question: What is cast member Roger Moore's (who has the occupation of voice actor) character role in Octopussy?
Choices:
War Machine
Libby Smith
Gimli
Josiah Bartlet
Dieter Reinhardt
Mr. Potato Head
Becky Sharp
James Bond
Robin Scherbatsky Sr.
Kunta Kinte
Answer: James Bond
SPARQL: SELECT DISTINCT ?qpv WHERE { ?e_1 <pred:name> "Octopussy" . ?e_2 <pred:name> "Roger Moore" . ?e_2 <occupation> ?e_3 . ?e_3 <pred:name> "voice actor" . ?e_1 <cast_member> ?e_2 . [ <pred:fact_h> ?e_1 ; <pred:fact_r> <cast_member> ; <pred:fact_t> ?e_2 ] <character_role> ?qpv .  }
Program:
function: Find
inputs: Octopussy
function: Find
inputs: voice actor
function: Relate
dependencies: 1
inputs: occupation
backward
function: Find
inputs: Roger Moore
function: And
dependencies: 2
3
function: QueryRelationQualifier
dependencies: 0
4
inputs: cast member
character role