1.

What is the difference between Stack and Queue?

Answer»
 StackQueue
1.Objects accessed on Last In First Out (LIFO).Objects accessed on First In First Out (FIFO)
2.Object PUSHED on TOP of collectionObject INSERTED at the end
3.Object REMOVED from the topObject removed from the beginning.
4.Two operations are called push and popTwo operations are called enqueue and dequeue


Discussion

No Comment Found