Question: What is the relation between Sardinia (the one that locates in the continent of Europe) and the Mediterranean Sea?
Choices:
works in collection
twinned administrative body
family name
located in time zone
located in or next to body of water
lifestyle
geography of topic
head of state
coextensive with
Wikidata property
Program:
function: Find
inputs: Europe
function: Relate
dependencies: 0
inputs: continent
backward
function: Find
inputs: Sardinia
function: And
dependencies: 1
2
function: Find
inputs: Mediterranean Sea
function: QueryRelation
dependencies: 3
4
SPARQL: SELECT DISTINCT ?p WHERE { ?e_1 <pred:name> "Sardinia" . ?e_1 <continent> ?e_3 . ?e_3 <pred:name> "Europe" . ?e_2 <pred:name> "Mediterranean Sea" . ?e_1 ?p ?e_2 .  }
Answer: located in or next to body of water