Computer Science, asked by shaiquanaaz222222, 11 months ago

write an algorithm to insert an element in a queue​

Answers

Answered by BrainlyFIRE
4

Hi mate......!!!!!!!

Start

Check if the Queue is full or not if(rear=N-1) THEN print “Queue is Full” and exit else goto step 3

Increment the rear ++rear;

Add the item at the ‘rear’ position Q[rear]= item;

Exit

Answered by raoshabh05
0

Answer:

check if the queue is full or not if (rear=n=1)

Then print "queue is full" and exit else go to step 3.

Add the item at 'rear' position Q(rear) =item

After exit.

Similar questions