DS Reference Programs - Module 2

Stack, Recursion, Queue

Home > Courses > DS > Demo M2


Warning! You are warned against blindly copying the code statements. Read the code and understand the implementation. Then, try to do it yourself. Blindly re-typing the code statements is a waste of time & effort.

Table of contents:

1. Simple stack (Using global array)

2. Stack using structure (Global structure instance)

3. Stack using structure (Local structure instance created in main)

4. Infix to postfix conversion

5. Evaluation of postfix expression

6. Recursion

6.1 Factorial of a number

6.2 GCD of two numbers

6.3 Exponentiation

6.4 Fibonacci series

6.5 Tower of Hanoi

6.6 Binary Search

7. Linear Queue using array

8. Circular Queue using Array

9. Improved Circular Queue using Structure