Course Hive
Search

Welcome

Sign in or create your account

Continue with Google
or
Lecture 97: Print all Elements in Queue | Implement Queue using Stack | Implement Stack using Queue
Play lesson

DSA Playlist in C++ - Lecture 97: Print all Elements in Queue | Implement Queue using Stack | Implement Stack using Queue

5.0 (0)
13 learners

What you'll learn

This course includes

  • 204.3 hours of video
  • Certificate of completion
  • Access on mobile and TV

Summary

Keywords

Full Transcript

Queue | 180daysofCode | Solve Many Problem on Queue | DSA 1: Reverse Queue: https://www.geeksforgeeks.org/problems/queue-reversal/1?page=1&difficulty%5B%5D=-1&category%5B%5D=Queue&sortBy=submissions 2: Reverse First K Elements of Queue: https://www.geeksforgeeks.org/problems/reverse-first-k-elements-of-queue/1?page=1&difficulty%5B%5D=0&category%5B%5D=Queue&sortBy=submissions 3: TIme Needed To Buy Tickets: https://leetcode.com/problems/time-needed-to-buy-tickets/submissions/1173348790/ 4: Implement Stack Using Queue: https://leetcode.com/problems/implement-stack-using-queues/submissions/1173361790/ 5: Implement Queue using Stacks: https://leetcode.com/problems/implement-queue-using-stacks/description/ 00:00 Intro 00:29 Problem 1 - Print all element in queue 2:15 Approach 1 - O(n) - Print all element without removing from queue 4:48 Approach 2 - O(1) Print all element without removing from queue 7:55 Code Part - Print all elemet without removing from queue 9:34 Problem 2 - Queue Reversal - Approach 1 10:45 Queue Reversal - Approach 2 15:24 Code Part- Queue Reversal 17:02 Problem 3 - Reverse First K elements of queue 25:17 Code Part - Reverse First K elements of Queue 27:31 Porblem 4 - Time needed to buy Tickets 41:53 Code Part - Time needed to buy Tickets 45:39 Time Complexity - Time needed to buy Tickets 46:39 Approach 2 - Time needed to buy Tickets in 0(n) Complexity/Home Work 53:16 Problem 5 - Implement queue using Stack 1:08:41 Code Part - Implement Queue using Stack 1:13:21 Time Complexity - Implement Queue using Stack 1:15:13 Problem 6 - Implement Stack using Queue 1:26:43 Code Part - Implement Stack using Queue 1:32:06 - Home work Home work sheet: https://drive.google.com/drive/folders/1N9UUtFHRe5a8h1vq3iEVEyvXM5sZDRHv?usp=sharing Join Our Whatsapp Channel: https://whatsapp.com/channel/0029Va6H0tbHVvTbcuT99Y1f Day 143/180, #180daysofcode #180 hard We are doing 180 days challenge and going to complete the whole course within the duration with quality content on Youtube. I am on the mission to create a tech revolution in our country and in upcoming future we want to create a tech which will create many jobs in India. Video will come on Mon-Fri at 6am in the morning DSA Course for free C++ Free Course Rohit Negi DSA Course C++ Coder Army DSA Course c++ Function in C++ Pointers in C++. Strings Vector Introduction to Recursion connect to me on Instagram: https://rohit978.page.link/insta Linkedin: https://rohit978.page.link/linkedin Telegram: https://rohit978.page.link/telegram

Course Hive

Continue this lesson in the app

Install CourseHive on Android or iOS to keep learning while you move.

Related Courses

FAQs

Course Hive
Download CourseHive
Keep learning anywhere