Question: How many contries surround the seas on the banks of which is the city of Cancun?
SPARQL:
SELECT DISTINCT COUNT(?uri) WHERE { ?x <http://dbpedia.org/property/cities> <http://dbpedia.org/resource/Cancún> . ?x <http://dbpedia.org/ontology/country> ?uri . }