Queue data structure is first in first out data structure also known as FIFO.
It can be used at many places typically for a producer consumer type of architecture where one component is producing information and other components are consuming them.
Queue allows us to implement loosely coupled architecture which has many benefits.
Ive explained that by using example of new york stock exchange sharing stock price information with yahoo finanace or google finance portals.
We will also implement Queue using collections.deque in python.
At the end we have an interesting exercise for you to solve.
Code in this tutorial:
Exercise:
Topics
00:00 Stock price exchange without Queue
02:57 Stock price exchange using Queue
05:12 Queue classes in different programming languages
05:45 List as Queue in python
07:55 collections.deque as Queue
12:58 Exercise
datastructures algorithms python
Do you want to learn technology from me? Check for my affordable video courses.
Next Video:
Previous video:
Complete playlist:
Website:
Facebook:
Twitter:
Источник: rutube.ru