Question: How is Cairo, twinned administrative body of Lagos, related to Beirut, twinned administrative body of Los Angeles?
Choices: sponsor
appointed by
contains administrative territorial entity
award received
film editor
owned by
capital of
twinned administrative body
film distribute region
professional or sports partner
SPARQL: SELECT DISTINCT ?p WHERE { ?e_1 <pred:name> "Cairo" . ?e_1 <twinned_administrative_body> ?e_3 . ?e_3 <pred:name> "Lagos" . ?e_2 <pred:name> "Beirut" . ?e_4 <twinned_administrative_body> ?e_2 . ?e_4 <pred:name> "Los Angeles" . ?e_1 ?p ?e_2 .  }
Program:
function: Find
inputs: Lagos
function: Relate
dependencies: 0
inputs: twinned administrative body
backward
function: Find
inputs: Cairo
function: And
dependencies: 1
2
function: Find
inputs: Los Angeles
function: Relate
dependencies: 4
inputs: twinned administrative body
forward
function: Find
inputs: Beirut
function: And
dependencies: 5
6
function: QueryRelation
dependencies: 3
7
Answer: twinned administrative body