MCQ IN COMPUTER SCIENCE & ENGINEERING

COMPUTER SCIENCE AND ENGINEERING

DATA STRUCTURES

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
The elements in a queue are added at one end called ____
A
front
B
rear
C
near
D
none of above
Explanation: 

Detailed explanation-1: -The insertion of an element in a queue is called an enqueue operation and the deletion of an element is called a dequeue operation.

Detailed explanation-2: -In Linear Queue, an insertion takes place from one end while the deletion occurs from another end. The end at which the insertion takes place is known as the rear end, and the end at which the deletion takes place is known as front end. It strictly follows the FIFO rule.

Detailed explanation-3: -A queue is an abstract data type that holds an ordered, linear sequence of items. You can describe it as a first in, first out (FIFO) structure; the first element to be added to the queue will be the first element to be removed from the queue. New elements are added to the back or rear of the queue.

Detailed explanation-4: -Queue is a non-primitive linear data structure that permits insertion of an element at one end and deletion of an element at the other end. The end at which the deletion of an element take place is called front, and the end at which insertion of a new element can take place is called rear.

There is 1 question to complete.