Consider the following code:
my_stack = [2, 5, 7]
my_stack.append(9)
my_stack.pop()
my_stack.append(11)
my_stack.pop()
my_stack.pop()
What is the top element of the stack?
Consider the following code:
my_stack = [2, 5, 7]
my_stack.append(9)
my_stack.pop()
my_stack.append(11)
my_stack.pop()
my_stack.pop()
What is the top element of the stack?
Create a free account to access the full topic