Question: Which Canadian college is headquartered in Toronto?
Choices:
Trinity College
Ontario New Democratic Party
Ontario Liberal Party
Fashion Institute of Technology
University College Dublin
Harvard College
Colorado College
Denison University
University of Toronto
Toronto FC
Program:
function: Find
inputs: Toronto
function: Relate
dependencies: 0
inputs: headquarters location
backward
function: FilterConcept
dependencies: 1
inputs: college
function: Find
inputs: Canada
function: Relate
dependencies: 3
inputs: country
backward
function: FilterConcept
dependencies: 4
inputs: college
function: And
dependencies: 2
5
function: What
dependencies: 6
SPARQL: SELECT DISTINCT ?e WHERE { ?e <pred:instance_of> ?c . ?c <pred:name> "college" . ?e <headquarters_location> ?e_1 . ?e_1 <pred:name> "Toronto" .  ?e <country> ?e_2 . ?e_2 <pred:name> "Canada" .  }
Answer: Trinity College