In a stack, if a user tries to remove an element from an empty stack it is called _________
A. Underflow
B. Empty collection
C. Overflow
D. Garbage Collection
Answer:A
In a stack, if a user tries to remove an element from an empty stack it is called _________
A. Underflow B. Empty collection C. Overflow D. Garbage Collection
Explanation: Underflow occurs when the user performs a pop operation on an empty stack. Overflow occurs when the stack is full and the user performs a push operation. Garbage Collection is used to recover the memory occupied by objects that are no longer used.