Match the functions with their descriptions:
Stack
Match functions and results
Report a typo
Match the items from left and right columns
peek()
push()
empty()
pop()
search()
Retrieves or fetches the first/top element of the stack without removing it from the stack
Returns the position of the element from the top of the stack, else it will return -1
Removes the object at the top of this stack and returns that object
Places the element at the top of the stack
Returns true if nothing is on the top of the stack, else, it will return false
___
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.
Create a free account to access the full topic
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.