Question: To which part of the democracy that has a diplomatic relation with United States of America (in the subject of Niger–United States relations) does the demonym ניז'רי apply?
Choices:
rest of the world
Northern Ireland
Garut
political union
teaching
Saint Pierre and Miquelon
Purwakarta
masculine
Alaska
Henderson County
Answer: masculine
SPARQL: SELECT DISTINCT ?qpv WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "democracy" . ?e <diplomatic_relation> ?e_1 . ?e_1 <pred:name> "United States of America" . [ <pred:fact_h> ?e ; <pred:fact_r> <diplomatic_relation> ; <pred:fact_t> ?e_1 ] <statement_is_subject_of> ?qpv_1 . ?qpv_1 <pred:value> "Niger–United States relations" . ?e <demonym> ?pv . ?pv <pred:value> "ניז'רי" . [ <pred:fact_h> ?e ; <pred:fact_r> <demonym> ; <pred:fact_t> ?pv ] <applies_to_part> ?qpv .  }
Program:
function: Find
inputs: United States of America
function: Relate
dependencies: 0
inputs: diplomatic relation
backward
function: QFilterStr
dependencies: 1
inputs: statement is subject of
Niger–United States relations
function: FilterConcept
dependencies: 2
inputs: democracy
function: QueryAttrQualifier
dependencies: 3
inputs: demonym
ניז'רי
applies to part