Showing posts with label QUESTIONS. Show all posts
Showing posts with label QUESTIONS. Show all posts

DIFFERENCE BETWEEN STACK AND QUEUE

 =>APPLICATIONS OF QUEUE:

1) simulation

2) time sharing system

3) CPU sheduling- round robin technique(RR)

4) Graph traversal technique(BFS)

5) Jobs sent to printer

6) ticket line, transection line.

=>QUE- What is the difference beyween STACK and QUEUE.
ANS-

=>SIMILARTIES:

1)BOTH ARE COLLECTION OF NODES.

2) BOTH ARE LINEAR DATA STRUCTURES.

MORE IMPORTANT ABOUT STACK


QUE:=>There is a que arise why we use two implementations of stack

=> the answer is there exit a main difference between two implementation(representation)
*In static we fix memory at the starting of repsntation
*Therefore memory fix 
*In efficient use of memory
While