A queue is a particular kind of abstract data type or collection in which the entities in the collection are kept in order and the principal (or only) operations on the collection are the addition of entities to the rear terminal position, known as enqueue, and removal of entities from the front terminal position, known as dequeue.

Queue is a First-In-First-Out (FIFO) data structure. In a FIFO data structure, the first element added to the queue will be the first one to be removed. This is equivalent to the requirement that once a new element is added, all elements that were added before have to be removed before the new element can be removed. Often a peek or front operation is also entered, returning the value of the front element without dequeuing it. A queue is an example of a linear data structure, or more abstractly a sequential collection.

Below is the list of commonly asked interview questions that uses queue data structure-

- Circular Queue Implementation in C

- Queue Implementation using Linked List

- Chess Knight Problem – Find Shortest path from source to destination

- Shortest path in a Maze | Lee algorithm

- Find shortest safe route in a field with sensors present

- Flood fill Algorithm

- Count the number of islands

- Find Shortest path from source to destination in a matrix that satisfies given constraints

- Generate binary numbers between 1 to N

- Calculate height of a binary tree | Iterative & Recursive

- Delete given Binary Tree | Iterative & Recursive

- Level Order Traversal of Binary Tree

- Spiral Order Traversal of Binary Tree

- Reverse Level Order Traversal of Binary Tree

- Print all nodes of a given binary tree in specific order

- Print left view of binary tree

- Find next node in same level for given node in a binary tree

- Check if given binary tree is complete binary tree or not

- Print Diagonal Traversal of Binary Tree

- Print corner nodes of every level in binary tree

- Breadth First Search (BFS) | Iterative & Recursive Implementation

- Minimum number of throws required to win Snake and Ladder game

- Check if an undirected graph contains cycle or not

- Invert given Binary Tree | Recursive and Iterative solution

- Print Right View of a Binary Tree

- Traverse the given directory using BFS and DFS in Java

**Thank you for being with us. 🙂**

## Leave a Reply