Share:
Notifications
Clear all

[Solved] CS301 GDB 1 Fall 2020


axxad paraxx
(@axxad-paraxx)
Reputable Member
Joined: 3 years ago
Posts: 263
Topic starter  

CS301 GDB 1 Fall 2020 solution idea:

 


Quote
admin
(@admin)
Admin
Joined: 4 years ago
Posts: 6752
 

CS301 GDB 1 Fall 2020 solution idea:

 

Queue Data Structure (FIFO) First In First Out

In my opinion queue data structure is best because of queue FIFO (first in first out). The queue is a line of items waiting to be served in sequential order. A queue is an ordered list in which insertions are done at one end (rear) and deletions are done at other ends (front). Working principle is First in First out (FIFO).

 

Stack Data Structure (LIFO) last in First Out

The stack is a linear data structure where the insertion of elements or deletions of elements is done from only one side/end which is called the top of the stack.

Stack allows access to only the last element inserted hence, an item can be inserted or removed from the stack from one end called the top of the stack.


ReplyQuote
Share: