#include #include "queue.h" #define FALSE 0 #define TRUE !FALSE #define MAXQUEUESIZE 4 struct queue { int elems[MAXQUEUESIZE]; } myQueue; /* return an empty queue */ struct queue *init ( ) { int k; for (k=0; kelems[0] == 0; } /* add an element to the end of the queue */ struct queue * enqueue (int val, struct queue *q) { /* You fill this in. */ return q; } /* remove the front of the queue; do nothing if the queue is empty */ struct queue * dequeue (struct queue *q) { /* You fill this in. */ return q; } /* return the front of the queue; undefined result if the queue is empty */ int front (struct queue *q) { return q->elems[0]; } /* print the queue */ void print (struct queue *q) { int k; for (k=0; kelems[k] == 0) { printf ("\n"); return; } else { printf ("%d ", q->elems[k]); } } printf ("\n"); }