Question: How is 4AD related to London which is in Europe?
Choices: commander of
medical treatment
headquarters location
residence
cause of death
legislative body
airline hub
basin country
award disciplines or subjects
place served by transport hub
SPARQL: SELECT DISTINCT ?p WHERE { ?e_1 <pred:name> "4AD" . ?e_2 <pred:name> "London" . ?e_2 <continent> ?e_3 . ?e_3 <pred:name> "Europe" . ?e_1 ?p ?e_2 .  }
Program:
function: Find
inputs: 4AD
function: Find
inputs: Europe
function: Relate
dependencies: 1
inputs: continent
backward
function: Find
inputs: London
function: And
dependencies: 2
3
function: QueryRelation
dependencies: 0
4
Answer: headquarters location