Question: What is the end time for william lamb, 2nd viscount melbourne has a position held as a Prime minister of the united Kingtom?
Paraphrase: When does William Lamb end his position?
SPARQL (Wikidata): SELECT ?value WHERE { wd:Q312567 p:P39 ?s . ?s ps:P39 wd:Q14211 . ?s pq:P582 ?value}