Queue Data Structure

‘Recent Articles’

Topic :

Introduction :

  1. Queue
  2. Applications of Queue Data Structure
  3. Priority Queue
  4. Applications of Priority Queue
  5. Deque
  6. Circular Queue

Implementation :

  1. Implement Queue using Stacks
  2. LRU Cache Implementation
  3. Implement Stack using Queues
  4. Queue | Set 2 (Linked List Implementation)
  5. How to efficiently implement k Queues in a single array?
  6. Implement a stack using single queue
  7. Implementation of Deque using circular array
  8. Circular Queue | Set 2 (Circular Linked List Implementation)

Standard Problems :

  1. Breadth First Traversal or BFS for a Graph
  2. Level Order Tree Traversal
  3. Construct Complete Binary Tree from its Linked List Representation
  4. Program for Page Replacement Algorithms | Set 2 (FIFO)
  5. Check whether a given Binary Tree is Complete or not | Set 1 (Iterative Solution)

Operations on Queue :

  1. Reversing a Queue
  2. Reversing the first K elements of a Queue
  3. Interleave the first half of the queue with second half

Misc :

  1. Level order traversal in spiral form
  2. Sliding Window Maximum (Maximum of all subarrays of size k)
  3. Find the largest multiple of 3 | Set 1 (Using Queue)
  4. Find the first circular tour that visits all petrol pumps
  5. Iterative Method to find Height of Binary Tree
  6. An Interesting Method to Generate Binary Numbers from 1 to n
  7. Minimum time required to rot all oranges
  8. Find maximum level sum in Binary Tree
  9. Sum of minimum and maximum elements of all subarrays of size k.
  10. Distance of nearest cell having 1 in a binary matrix
  11. Level order traversal line by line | Set 2 (Using Two Queues)
  12. First negative integer in every window of size k
  13. Minimum sum of squares of character counts in a given string after removing k characters
  14. Queue based approach for first non-repeating character in a stream
  15. Averages of Levels in Binary Tree
  16. Stack Permutations (Check if an array is stack permutation of other)
  17. Check if all levels of two trees are anagrams or not
  18. Check mirror in n-ary tree

Quick Links :

Company Wise Coding Practice    Topic Wise Coding Practice