How many {architect} are to/by {Gian Lorenzo Bernini} ?
What is the number of buildings that architect Gian Lorenzo Bernini designed?
How many buildings were designed by architect Gian Lorenzo Bernini?
SELECT ( COUNT ( ?t ) AS ?k ) { ?t property:architect resource:Gian_Lorenzo_Bernini }
SELECT (COUNT(?sub) AS ?subs ) {
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> ?sub .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P84> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> http://wikidata.dbpedia.org/resource/Q160538 .
} 

SELECT (COUNT(?sub) AS ?value ) { ?sub wdt:P84 wd:Q160538 }
14