## Depth first search (DFS) vs Breadth first search (BFS)

In this post, we will see the difference between Depth first search (DFS) and Breadth first search (BFS) algorithm which are used to traverse/search tree or graph data structure.

Coding made easy

In this post, we will see the difference between Depth first search (DFS) and Breadth first search (BFS) algorithm which are used to traverse/search tree or graph data structure.

In this post, we will discuss how to efficiently implement two stacks in a single array.

Given a stack, sort it using recursion. The use of any other data structures (like containers in STL or Collections in Java) is not allowed.

In this post, we will see how to implement a queue using stack data structure in C++ and Java. In other words, design a queue that supports enqueue and dequeue operations using standard push and pop operations of the stack.

Write an efficient algorithm to find preorder traversal of a binary tree from its inorder and postorder sequence without constructing the tree.

Design a stack to support an additional operation which returns the minimum element from the stack in constant time. The stack should continue supporting all other operations like push, pop, top, size, empty, etc, with no degrade in performance for these operations.

Given a string consisting of opening and closing parenthesis, find the length of the longest balanced parenthesis in it.

In this post, we will see how to reverse an array in C++.

In this post, we will discuss how to reverse a string using stack data structure.

Given a binary tree, write an iterative algorithm to print leaf to root path for every leaf node of binary tree. Use of Recursion is prohibited.

Given a binary tree, write an efficient algorithm to invert binary tree.