asked 51.3k views
3 votes
)In a vector implementation of a stack ADT, you clear all of the contents of a stack using which vector method

a. Clear

B. Delete

C. Delete all

D. None of the other answers

1 Answer

6 votes

Answer: a)Clear

Explanation: Stack ADT(Abstract Data type) is the datatype that works in the form of the group of elements having the insertion and deletion of the object by last in first out mechanism.

When there is the vector implementation on stack of ADT then, for removing all the elements from the collection is done by using the command "clear".thus option (a) is the correct option.

answered
User Chronikum
by
7.8k points