# Help Me/QuestionHow To Implement D-queue In C?

#### steve taylor

White Belt
Queue is a data structure and d-queue is an operation which performed on queue for deleting the data from queue. The property of the queue is first in first out (FIFO) that means which element comes in queue first that element go out from the queue first . Example :-
Line on the ticket Booking counter.

#### krishatg

##### Content Writer
D-queue is not function it is another type of queue called as double ended queue in which you can insert or delete on either side of the queue. It further dive into two parts
1. entry restricted d-queue
2. exit restricted d-queue

#### steve taylor

White Belt
D-queue is not function it is another type of queue called as double ended queue in which you can insert or delete on either side of the queue. It further dive into two parts
1. entry restricted d-queue
2. exit restricted d-queue
You are right , You are explaining double ended queue. But I am talking about queue operation like En_ queue (Insertion of element to the queue) and D_ queue (deletion of element from the queue). Now I hope you can understand my question.

#### VIVEK KUMAR

White Belt
ADT of the queue are as follows -
• Is Queue id full.
• Is Queue is Empty
• Enque and
• Dqueue

We can implement dqueue operation as follows -

Code:
``````int Dqueue (Q, N, F, R)
int y;
{
if (F==R==-1)
{
printf("Queue is under flow means no element in queue")
}
else
{
y= Q [F];
if (F==R)
F = R = -1;
else
F = F + 1;
return (y);
}
}``````
Q - Denote the queue.
N- Denote the number of element in Queue
F - front variable
R - rear variable

#### Swati Mishra

##### Content Writer
D-queue is the abstract datatype which is used for insertion and deletion. it allow to insert and delete from the both sides.