Question: What country that is ruled by Maria Theresa has the capital of Budapest?
Answer(s):
answer: Hungary

SPARQL query:
PREFIX ns: <http://rdf.freebase.com/ns/>
SELECT DISTINCT ?x
WHERE {
FILTER (?x != ns:m.0czh6)
FILTER (!isLiteral(?x) OR lang(?x) = '' OR langMatches(lang(?x), 'en'))
ns:m.0czh6 ns:royalty.monarch.kingdom ?x .
?x ns:location.country.capital ns:m.095w_ . 
}