Question: What is the ISO 3166-2 code for the administrative-territorial entity that has Perth as its capital, the one whose country is Kingdom of Great Britain?
Choices:
BR-MG
GB-PKN
IN-TN
FR-50
IN-AR
BR-RJ
US-IL
US-NC
IN-CT
DE-TH
Program:
function: Find
inputs: Kingdom of Great Britain
function: Relate
dependencies: 0
inputs: country
backward
function: Find
inputs: Perth
function: And
dependencies: 1
2
function: Relate
dependencies: 3
inputs: capital
backward
function: FilterConcept
dependencies: 4
inputs: administrative territorial entity
function: QueryAttr
dependencies: 5
inputs: ISO 3166-2 code
SPARQL: SELECT DISTINCT ?pv WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "administrative territorial entity" . ?e <capital> ?e_1 . ?e_1 <pred:name> "Perth" . ?e_1 <country> ?e_2 . ?e_2 <pred:name> "Kingdom of Great Britain" .  ?e <ISO_3166-2_code> ?pv .  }
Answer: GB-PKN