Queue NCERT Solution || Queue Class 12 Solution || Queue Class 12 CS Solution || Queue Computer Science Solution || NCERT Queue Python Solution || Queue Class 12 CS || Queue in Python Solution


Note :-  Please Click on Question to get Solution of that Question !!


Q1. Fill in the blank

a) ____________________ is a linear list of elements in which insertion and deletion takes place from different ends.
b) Operations on a queue are performed in __________________ order.

c) Insertion operation in a queue is called ______________ and deletion operation in a queue is called
____________________.
d) Deletion of elements is performed from _______________ end of the queue.
e) Elements ‘A’,’S’,’D’ and ‘F’ are present in the queue, and they are deleted one at a time, ________________________ is the sequence of element received.
f) _______________ is a data structure where elements can be added or removed at either end, but not in the middle.
g) A deque contains ‘z’,’x’,’c’,’v’ and ‘b’ . Elements received after deletion are ‘z’,’b’,’v’,’x’ and ‘c’. _____________ is the sequence of deletion operation performed on deque.




Q2. Compare and contrast queue with stack.


Q3. How does FIFO describe queue?


Q4. Write a menu driven python program using queue, to implement movement of shuttlecock in it’s box.
  

Q5. How is queue data type different from deque data type?


Q6. Show the status of queue after each operation

enqueue(34)
enqueue(54)
dequeue()
enqueue(12)
dequeue()
enqueue(61)
peek()
dequeue()
dequeue()
dequeue()
dequeue()
enqueue(1)




Q7. Show the status of deque after each operation

peek()
insertFront(12)
insertRear(67)
deletionFront()
insertRear(43)
deletionRear()
deletionFront()
deletionRear()




Q8. Write a python program to check whether the given string is palindrome or not, using deque. (Hint : refer to algorithm 4.1)


Post a Comment

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Previous Post Next Post