Programming Teasure

Stack implementation using linked list representation in C++

Stack is an important data structure, which works on the principle of Last-In-First-Out(LIFO). It is used in memory modules for storing local variables and implementing recursive calls. It is also used in implementing Lexical analyzers(compilers) to check for syntactical errors. Besides this it can be used for inter-conversion of mathematical expressions(in-fix, post-fix and pre-fix notations).