Queue: A queue is a container of objects that are inserted and removed according to first-in-first-out(FIFO) principle.
[Problem]
Enqueue the given N (2 <=N <=100) numbers in order into a queue, then dequeue each and print on the screen.
[Input]
The first input line contains the number of test cases,T.
The...
Thursday, November 09, 2017
undefined
201
Stack: A stack is a container of objects that are inserted(push) and removed (pop) according to the last-in-first-out(LIFO) principle.
[Problem]
Insert(Push) the given N (2 <=N <=100) numbers in order into a stack, then pop each and print on the screen.
[Input]
The first input line contains the number of...