Ejemplo n.º 1
0
def test_stack_last():
    s = Stack()
    s.push(1)
    assert s.last() == 1
    assert len(s) == 1 # the value is still on the stack