DSA Comic Part 2

DSA Comic Part 2
  Copy


More Options: Make a Folding Card




Storyboard Description

This storyboard does not have a description.

Storyboard Text

  • Oh so that's what a circular queue is
  • Did you know that circular queues were created as an effective solution for the rightward drift problem in linear queues?
  • What's the rightward drift problem
  • In linear queues, multiple sequences of addition and removals will result in items drifting towards the end of the array. Rightward drift will make the queue seems like it contains a large number of items but in actual fact, there are only a few items in the queue.
  • Oh, so that's the disadvantage of using linear queue instead of circular queues
  • After a slot is used to store an item, it can no longer be used to store another item even if the previous item was deleted, this results in the queue having a limited lifespan. Circular queues, on the other hand, are not affected by rightward drift as it is able to cycle back to previous slots
  • Dad, I  don't understand
  • OK, how about this. do you remember the Ferris wheel mentioned before?  If one person exits the cabin, another person is able to enter and use the cabin. Linear queues however do not allow other items to be placed on spaces that was once used by other items, even if the prevoius item was already deleted
  • Oh, so the advantage of using circular queues instead of linear queues is the efficient use of memory space.
More Storyboards By veradon
Explore Our Articles and Examples

Try Our Other Websites!

Photos for Class   •   Quick Rubric   •   abcBABYart   •   Storyboard That's TPT Store