In this tutorial, we will discuss about stacks in data structures. A stack is an ordered list in which items may be added or removed only at one end, called the “top” of the stack. The last item to be added to a stack is the first item to be removed .Accordingly, stacks are also called Last- in-first- out (LIFO) lists or First- in –out (FIFO) lists. The two basic operation associated with stack are
Examples
Top=Top+1
(Top==-1)
Top =Top-1;
You liked the article?
Like: 0
Vote for difficulty
Current difficulty (Avg): Medium
TekSlate is the best online training provider in delivering world-class IT skills to individuals and corporates from all parts of the globe. We are proven experts in accumulating every need of an IT skills upgrade aspirant and have delivered excellent services. We aim to bring you all the essentials to learn and master new technologies in the market with our articles, blogs, and videos. Build your career success with us, enhancing most in-demand skills in the market.