'Return the k\'th element back from the top of the stack.
peek(1) is the top of the stack.'

def peek(self, k):

    num_pops = k
    top_k = [self.pop() for _ in range(num_pops)]
    r = top_k[(-1)]
    for i in range((num_pops - 1), (-1), (-1)):
        self.push(top_k[i])
    return r
