Question: Which dynasty's country is the sovereign state with the UIC numerical country code of 31?
Choices: Borjigin
House of Stuart
Russian
House of Orange-Nassau
House of Bernadotte
Russians
House of Plantagenet
House of Hohenzollern
Imperial House of Japan
Mongolia
SPARQL: SELECT DISTINCT ?e WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "dynasty" . ?e <country> ?e_1 . ?e_1 <pred:instance_of> ?c_1 . ?c_1 <pred:name> "sovereign state" . ?e_1 <UIC_numerical_country_code> ?pv . ?pv <pred:value> "31" .   }
Program:
function: FindAll
function: FilterStr
dependencies: 0
inputs: UIC numerical country code
31
function: FilterConcept
dependencies: 1
inputs: sovereign state
function: Relate
dependencies: 2
inputs: country
backward
function: FilterConcept
dependencies: 3
inputs: dynasty
function: What
dependencies: 4
Answer: Borjigin