Please fill C/C++ code in the blank spaces in the following program segments so that adding an item to a circular queue
Posted: Tue Apr 12, 2022 10:20 am
Please fill C/C++ code in the blank spaces in the following program segments so that adding an item to a circular queue can be correctly functioned. When you add an element to full circular queue, you must cal . queue_full(rear). When you delete an element to empty circular queue, you must call queue_empty(). element queue[MAX-QUEUE-SIZE]; //MAX-QUEUE-SIZE is the size of the circular queue /* Adding an item to a circular queue */ void addq(int front, int *rear, element item) { (1). if (_(2)){ queue_full(rear); return; } (3) return;