Question: Gujarat (which uses Hindi language) shares a border with Sindh, what country is it a part of.
Choices:
Serbia
Portugal
Georgia
Sint Maarten
India
Hungary
Pakistan
Confederation of the Rhine
Kuwait
Austria
Answer: Pakistan
SPARQL: SELECT DISTINCT ?qpv WHERE { ?e_1 <pred:name> "Gujarat" . ?e_1 <language_used> ?e_3 . ?e_3 <pred:name> "Hindi" . ?e_2 <pred:name> "Sindh" . ?e_1 <shares_border_with> ?e_2 . [ <pred:fact_h> ?e_1 ; <pred:fact_r> <shares_border_with> ; <pred:fact_t> ?e_2 ] <country> ?qpv .  }
Program:
function: Find
inputs: Hindi
function: Relate
dependencies: 0
inputs: language used
backward
function: Find
inputs: Gujarat
function: And
dependencies: 1
2
function: Find
inputs: Sindh
function: QueryRelationQualifier
dependencies: 3
4
inputs: shares border with
country