Posts

Showing posts from October, 2020

Queue Data Structure

Image
  QUEUE DATA STRUCTURE     This diagram shows a queue data structure. It just like a queue. It has two open end. We can do three operations with stack data structure.          i.           Enqueue / push      ii.           Dequeue / pop     iii.           Front / peek     This stack data structure also called as “ First In First Out ” structure. The element which entered first, can get out first.     E.g:   The better example is the Printer in an Office Network. It can receive many requests at a time. But It process the request which come first. That means first in first out.

Stack Data Structure

Image
  STACK DATA STRUCTURE   This diagram shows a stack. It just like a box. It has one open end. We can do three operations with stack data structure.          i.           Input / push      ii.           Remove / pop     iii.           See most upper element ( peek / top )     This stack data structure also called as “ Last In First Out ” structure. Because user can see the most upper element first. The element which entered first, can see in last.