Java provides an inbuilt object type called Stack. It is a collection that is based on the last in first out (LIFO) principle. On Creation, a stack is empty. It extends Vector class with five methods that allow a vector to be treated as a stack. The five methods are: 1. Object push(Object element) :… Read More »
See Placement Course for placement preparation, GATE Corner for GATE CS Preparation and Quiz Corner for all Quizzes on GeeksQuiz.